Kako prilagoditi Android uređaj navikama i potrebama

Advertisements

Begin MVC with CodeIgniter (PHP) – Sample Login

diluk's techtalk

Source File : Click here to download (Locate the extracted folder inside wamp->www folder and run by localhost)

CodeIgniter is a simple yet powerful MVC(Model-View-Controller) framework for PHP. In this post I’m gonna share you a simple login app that is developed using this framework to give you a basic understanding on how to start developing with this. This example will focus on handling controllers to serve the user with different views as well as passing data from the views to controllers and validate/process them inside the controller using functions.

ci_ex01

01. First what you should do is setting up the base url inside application->config->config.php
(You need to give the server path that your project resides) In my case I have set my base url as follows,
$config[‘base_url’] = ‘http://localhost:8080/my_ci_app/’;
 
02. In the index function of welcome.php, inside application->controllers, you set the view that the user should see at the…

View original post 161 more words

CodeIgniter – Tips

ronscript blog

(Why should we use $_SERVER[‘SERVER_NAME’] and not LOCALHOST in base_url ?)

$_SERVER[‘SERVER_NAME’] – this will produce the exact server name. For example: your computer’s IP is 192.168.0.2 and echo $_SERVER[‘SERVER_NAME’] the output is:

input : echo $_SERVER[‘SERVER_NAME’];

output: 192.168.0.2

Issue: (note: assuming that you are a SERVER) If you are using base_url() and set it to (localhost/www/site/) to extend that path of your css, scripts links etc. This would be helpful. For example: <?php echo base_url(‘assets/css/bootstrap.css’); ?> this will produce http://localhost/www/site/assets/css/bootstrap.css. If the CLIENT request for the site no css file will be loaded because its also producing the url of css to LOCALHOST. That’s the reason we should use $_SERVER[‘SERVER_NAME’], it will produce the right servername.

View original post

IMPORTANCE OF CODE IGNITER

Freelance Remote Developer

Code Igniter is powerful and open supply internet applications, that is that the one in the entire foremost well-liked PHP framework. It includes a content management system that helps in making price economical PHP solutions. Code Igniter Development helps do additional simply and an improved manner, you’ll be able to produce code which can be easier to browse and write you’ll be able to conjointly save time, build your internet safer and strong through CodeIgniter PHP Development. CodeIgniter is free, light-weight, and easy to put in. PHP is AN open supply server facet scripting and programing language permits simple insertion in hypertext mark-up language code and info property to MYSQL and PgSQL Databases.

Code Igniter would be best suited if:

•             You want to make a framework with a small footprint

•             You need outstanding presentation of performance

•             I case you need intensive compatibility once coping with regular…

View original post 343 more words

Code Igniter Web Development: A Popular PHP Framework

Sean PHP Remote Works

Here is one more treat for all those developers WHO use PHP as their main platform to style and develop partaking and dynamic websites. Yes, we have a tendency to are talking regarding CodeIgniter internet development. we all know that there are an entire heap of great open supply frameworks in Codeigniter internet Development are place to use for obtaining fast internet application development. Code Igniter internet development framework remains the foremost in style one within the class. This too returns within the MVC pattern that facilitates the online developers in reworking the illustrative still as innovative ideas that the users come up with into real applications. For those that shun away any reasonably complexness and would wish effective and straightforward solutions, it’s then CodeIgniter for them undoubtedly.

The main profit that one will get with the assistance of CodeIgniter is competent solutions in internet development that render effective service…

View original post 324 more words

How to Integrate Custom template to Codeigniter?

PHP WEB DEVELOPER

Before going to topic we need to know the folder structure of Codeigniterimg1
Step1:
Here we need to copy images to images folder and css to css folder js to js folder of static template files
Under parent folder views we need to create child folder as templates under templates we need to create views/templates/Index.php file, then copy the static template index.html to views/templates/Index.php.
Step 2:
Move to applications/ libraries here we need to create two files i.e like below

Settemplate.php

<?php if (!defined('BASEPATH')) exit('No direct script access allowed');
class CI_Settemplate
{

CI=& get_instance();
$this->CI->load->library("template");
}
public function maintemp($view, $data="", $title="Family")
{
$content=$this->CI->load->view($view, $data, true);
$login =$this->CI->load->view("formdata/usersearch",$data,true);
$this->CI->template->set_template("maintemp");
$this->CI->template->write ('content',$content);
$this->CI->template->write ('login',$login);
$this->CI->template->write ('title',$title);
$this->CI->template->render();
} public function innertemp($view, $data="", $title="Family")
{ $content=$this->CI->load->view($view, $data, true);
$menu =$this->CI->load->view("templates/menu",$data,true);
$this->CI->template->set_template("innertemp");
$this->CI->template->write ('content',$content);
$this->CI->template->write ('menu',$menu);
$this->CI->template->write ('title',$title);
$this->CI->template->render();
}
}
?>

Need to add Template.php that look like below


class CI_Template {

var…

View original post 1,757 more words

Paypal direct payment method

Developer Blog

1.firstly you shoud have paypal account to use the payment method
2.Then you need credentials of credit card from the customer so that he can pay
$api_version = ‘98.0’;
$api_endpoint = ‘https://api-3t.sandbox.paypal.com/nvp’;
$api_username = ”;
$api_password = ”;
$api_signature =”;
// Store request params in an array
$request_params = array
(
‘METHOD’ => ‘DoDirectPayment’,
‘USER’ => $api_username,
‘PWD’ => $api_password,
‘SIGNATURE’ => $api_signature,
‘VERSION’ => $api_version,
‘PAYMENTACTION’ => ‘Sale’,
‘IPADDRESS’ => $_SERVER[‘REMOTE_ADDR’],
‘CREDITCARDTYPE’ => $ctype,
‘ACCT’ => $cnumber,
‘EXPDATE’ => $e,
‘CVV2’ => $cvv,
‘FIRSTNAME’ => $fname,
‘LASTNAME’ => ‘Testerson’,
‘STREET’ => ‘707 W. Bay Drive’,
‘CITY’ => ‘Largo’,
‘STATE’ => ‘FL’,
‘COUNTRYCODE’ => ‘US’,
‘ZIP’ => $zip,
‘AMT’ => $amount,
‘CURRENCYCODE’ => ‘USD’,
‘DESC’ => ‘Testing Payments Pro’
);

// Loop through $request_params array to generate the NVP string.
$nvp_string = ”;
foreach($request_params as $var=>$val)
{
$nvp_string .= ‘&’.$var.’=’.urlencode($val);
}

// Send NVP string to PayPal and store response

View original post 42 more words