PHP $_SERVER

Hello everyone, today we are going to learn PHP $_SEVER variable. Which is a super global variable and contains header information, path information, script locations. They are available in all scopes throughout a script. Entries to this global variable is done by web server. Below table describes $_SERVER variables and its use. CODE DESCRIPTION $_SERVER[‘PHP_SELF’] […]

Continue Reading

Codeigniter HMVC

HMVC stands for Hierarchical Model View Controller(HMVC). Why developers use HMVC instead of MVC is of handling  n-tier Web architecture or multi -tier. Here,  the software is engineered to have the processing, data management, and presentation functions physically and logically separated. The HMVC pattern decomposes the client tier into a hierarchy of parent-child MVC layers. This is […]

Continue Reading

Some Important Codeigniter Helper Functions to Validate User Input Data

Our PHP codeigniter framework has lot of functions to validate user input data. Before using this functions, you need load respective helpers. xss_clean() –  Function filter cross-site script from a string. Before use this function user need to load $this->load->helper(‘security’); Syntax : xss_clean($str); Return string. Example $str = ‘Hello<script>alert(“alert box”);</script>’; echo xss_clean($str); // result :Hello[removed]alert(“alert […]

Continue Reading

Export a MySQL database Query Result as an XML Document using Codeigniter

Dear friends, Using database utilities class we can export MySQL database data as XML Document.Then,  What is an XML document?. XML stands for Extensible Markup Language. Self descriptive in nature. XML stores data in plain text format. In order to initialize the utility class, ensure that the database class is running in your codeigniter application. Step […]

Continue Reading

Export Query Results as CSV File Using Codeigniter

Dear friends, In codeigniter, there is a database utilities class to export MySQL database data as CSV File. In order to initialize the utility class, ensure that the database class is running in your codeigniter application. F Friends, follow these steps to export query results as CSV file using your codeigniter application. Step 1: Download […]

Continue Reading