Manipulating with date and time on PHP

November 7th, 2011 | Posted under Internet Trends, Software, Uncategorized | No Comments »

Manipulating with date and time on PHP

The websites that are most updated is considered to be the most visited and sought after domain. However it is not possible for all the organizations to constantly upload volumes of articles and contents in a web page. So instead of laboring uselessly the website owners that have built their web pages upon PHP seek to use it in a different way. PHP allows manipulation of web pages along with their date and time. The features of PHP’s date and time manipulation function allows a website to appear to any visitor as if it is up to date.

Manipulating with date and time on PHP

This date and time function of PHP is mostly used in printing out the current date and time on the web page. It allows the user to view a page which seems recently updated. The dates function represented as date() is used in PHP in a way so that it is able to draw out the required data from the available resources. This extraction of dates may involve what time of the day it is. Is it before noon or after it that is whether the time is am or pm. The date function is called during the date manipulation stunt in PHP. Here the string arguments that are provided in the function are vital in obtaining the exact date that would be showcased on the webpage.

Manipulating with date and time on PHP

The list of parameters that may be used in the date function can be like: AM or PM, hour, day, month and minutes. Even the format of the months may be changed. It can be represented like from 1 to 12 or from January to December. Similarly the hours in the day can be represented in two formats. That is if the format is being followed on the basis of 24 hours then the range is made from 00 to 23 hours. Even the time zone of the server can be regarded as a parameter of the date function. The days in a year can be different. Therefore the information regarding whether there are 365 or 366 days in the year can also be deduced while using this function during manipulation.

Manipulating with date and time on PHP

Year can be represented as two digits which is a tried and tested convention. When we only take the last two digits while referring to the year we may use that parameter. Whereas we can also take the more formal method of writing the full year number which in that case would be comprised of four digits. It is always advised that while writing these parameters in PHP we should use single quotes to denote the values. Using double quotes may lead you into trouble if you by chance any character.

This PHP time stamp accepts the numeric values. It is notable that the time stamp of PHP uses a base time or reference time of 1st January, 1970. The time and date manipulation functions of PHP are used by numerous websites and within them quite a few are reputed ones. It is evident from this fact that the time and date is a vital factor in keeping a website appears updated to its users. This in turn produces a lasting effect on the user. When a website appears updated the general feeling about the content posted in the site and about its authors becomes better. The time stamp on the website can verified with the echo function which only shows the manipulated dates. The echo date format is also represented in the month-day-time form.

Get the best of PHP functions by hosting your application with Bounceweb Hosting!


Choosing Between ASP, JSP And PHP

September 27th, 2011 | Posted under The Internet, Web Hosting, Web Hosting Tips | No Comments »

Choosing Between ASP, JSP And PHP

Websites are the integral part of internet, so if you need to promote or make people aware about something through internet then you need to have your private website where you can post all the information to make it available to the whole world. But the problem is that there are millions of such websites available on net, so your website must be something different from others to make it more appealing than others.

Choosing Between ASP, JSP And PHP

This can be achieved by using dynamic scripting languages. These languages are actually scripts which are meant for carrying out some extensive work on the server. All these scripting languages gives you power to properly manage all yours hosting accounts over internet. The most popular scripting languages that are available for all these purposes are ASP, PHP, JAP, python and many others. But among them, ASP, PHP and JSP are mainly used as they are easy to learn and implement. Also each of these scripting languages has their own field of expertise, so one should choose the appropriate scripting language depending upon requirement and other external factors.

ASP is one of the most popularly used scripting languages and its full form is “Active Server Page”. Microsoft is the owner of this scripting language and one has to buy its license before using it. The most important feature of ASP is its dynamic scripting capability.  The next higher version of ASP is ASP.net which further improves its dynamic capability. ASP.net is also provided with the power where one can use more than one type of language in designing the webpage. This software is compatible in all Windows servers as both the products are owned by Microsoft and can be used along with Microsoft SQL.

JSP is another popular scripting languages and its full form is “Java Server Pages”. As the name itself suggests this scripting language runs on Oracle Sun Java which is a very powerful programming language. This scripting language is mainly helpful in enterprise solution companies as this script is mainly functional in the server side. This scripting also is very popular among programmers as it uses servlet, a very well known architecture which can work with HTML language in creating websites. But this language is more complex compared to Asp, so it is advised for expert use but on the other hand it gives more flexibility than ASP.

 

Choosing Between ASP, JSP And PHP

Another well known scripting language is PHP whose full form is Hypertext Pre-processor.  This is the easiest among all scripting languages and can be very easily learnt by reading books without any expert’s advice.  This is an open source scripting language and is common among both webmasters and developers. There are a lot of tools present which guides the programmer in the right direction and makes programming easier.

Choosing Between ASP, JSP And PHP

So we have discussed the properties of various scripting language and from that one can easily identity that each of these scripting languages have some benefits over others. So it’s completely up to the user to select the correct scripting language to achieve his or her objective to the optimum level.

Get the best of ASP, JSP and PHP hosting only on Bounceweb Hosting!


Using JavaScript and PHP to validate forms

March 12th, 2011 | Posted under The Internet, Web Hosting Tips | No Comments »

Using JavaScript and PHP to validate forms

When we need to construct a website the most important thing that we need is a form, which is considered as the best method of collecting vital information from the visitors. The size and content of the form varies according the requirements like the subscription membership form is very large compared to login form, as it requires a lot of more information than the later. As the size of the form increases the processing cost and time increases and also it requires more advanced and expert programmers to solve this challenge.  The two important fields where need to focus about these forms are the gathering and intrusion to gather maximum useful data from the visitors. With the help of some tools we can eliminate almost ninety five percentages of intruders and letting visitors to provide only that useful information that we want. Such for optimization tools for inspection is available for both server and clients. The most popular tools on client side are various types of scripting languages, like Java-script, which is the most popular one for limiting and checking of form data. Similarly on the server side the recognized tool is known PHP.

Subscription membership form

using java-script and php to validate forms

Login form

Using java-script and php to validate forms

Facts about JavaScript

Java script as specified above is the most popular scripting language on the client side for designing web pages. The code of Java script is in HTML format and it works without any intervention of the client but can be modified by the client according to the requirement. Also the effects of the java script remains with the client till it is being submitted to server. This is not a programmable language rather a scripting language on the client side and deals with the objects on web pages.

Loophole of JavaScript

This scripting language is not a secured tool, as the main source files are sent to clients. Java script also sets some set of rules to prevent the use of the tool for evil intension but experts are able to break these rules to design malicious objects. So use of java script for form validations should be done with proper guidance.

Utilization of JavaScript and PHP for reducing traffic

Java scripts are capable to control the HTML objects and are able to control the network traffic s between the client and the server. When we have the access of bout java script and PHP, then we allow the java script to first check the constraints and also the client side, the rest of the work is handed to the PHP to manage the server side traffic and other related matters on the server side. Thus java script and PHP together helps in controlling the traffic and makes the process of validation of form more comfortable.

Data transfer operation between PHP and JavaScript

Sometimes there is a need to send some data back to client from server side for validation process. PHP has this feature too to send back the data to java script. This can be done by two ways, the first way is to add the PHP code directly in <> so this is can be easily identified by the java script and the second way is to inject a hidden input field to the page and integrate its value with the PHP. This feature allows a bidirectional data transfer making form validation more convenient.

Forms look a lot better when created using PHP with JavaScript and Bounceweb Hosting!


Relevance of PHP in the world of Web 2.0

March 12th, 2011 | Posted under Internet Trends, The Internet, Web Hosting Tips | No Comments »

Relevance of PHP in the world of Web 2.0

Relevance of php in the world of web 2.0

This era is considered to be a digital age and everything is related to the cyber territory. Whenever we consider our daily works, more or less 90% works are related with web that means 90% of our works are done in web like banking, job, reservation, chat, social networking, education, selling and what not. So, the web is totally covered the lives of human beings. Here comes the need of web interface to interact with the end users. And that is why the web programming languages comes into being.

Web Programming Languages

As the web is advancing forward, the web programming languages are being developed day by day with advanced characteristics. There exist many web programming languages like PHP, ASP, VB.NET, ASP.NET, JAVA, PYTHON etc. But amongst the aforesaid programming languages, the web territory in programming language, the PHP holds a large space. PHP was initially developed as Web Programming Language and later on PHP can be used in any case like Desktop Application Development. This web enveloped world is totally configured using Web Programming languages and PHP does this using its sophisticated advanced classes of syntax.

Web 2.0

Web 2.0 is totally a weird term to be explained. Initially web interface is developed with a minimal interaction signal events and later on, now web interface can be used for any work and now it includes many function abilities. This is called Web v2 or Web Version 2. And now-a-days it is seen that amongst all other web programming languages, PHP is wide-spread.

PHP Web Programming

PHP as a web programming language holds top place for web application development to interact with the end users. PHP is wide-spread as it contains many inbuilt functions to take the load off the web programmer and eventually it also includes many external advanced framework classes and extensions to work with the web 2.0 much better. PHP mainly uses extensions and modules. Extension and modules are extended libraries and classes to extend the programming interface to greater extent. For web application development, many frameworks are needed for security measures and even for socket connection; we need some extended modules or extension to work on sockets or protocols. For these, PHP can be easily used in large extend after loading the extensions. Even if we consider, social networking arena, PHP holds the top place as Facebook is totally developed using PHP. Even network programming can also be done using PHP. But for web 2.0, network programming or socket programming is not needed too much. We only need extended frameworks to work with the web 2.0 to better understand the relevance of PHP in this arena. Now-days, 99% websites are developed using PHP Frameworks like Joomla, Drupal, XOOPS, Froggy loops, phpBB, SMF and many more. These are extended version of php that includes many classes of their own to configure the web 2.0 according to the MVC design patterns.

PHP is largely used now-a-days but other web programming languages like python can also be used in large extent but not comparable to PHP as Orkut is made using Google-Python API, the Twitter is also made using Twitter-python API. Though if we consider in Toto, then PHP takes the top notch place in web 2.0 for interacting with the end users.

Host your PHP applications on Bounceweb for the best experience!


Top Five Sides of PHP Scripts

February 21st, 2011 | Posted under Internet Trends, The Internet, Web Hosting Tips | No Comments »

Top Five Sides of PHP Scripts

Top Five Sides For PHP Scripts

We know that this era is a digital on the basis of everything. Everything is digitally signature. Even we can’t say anything which does not relate the cyber territory. So, here comes the point of thinking about how the digital signatures are made. Here comes the word “PROGRAMMING LANGUAGE”. A programming language digitally signatures a digital equipment. There are different kinds of programming languages which are used now-a-days.

Different Kinds of Programming Languages

Mainly programming languages are same if we consider the concepts. Though there exist different kinds of programming languages like C, C++, VB (Visual basic), ASP (Active Server Pages), ASP.NET, VB.NET, PHP, JAVA, Server Side JavaScript, Python etc. These all are same according to their concepts. They differ in the sense of their usage in syntax. Some of these programming languages are grouped according to the ease of access. Like ASP, PHP are considered to be in the Web Programming Language Group. Python is in software development group. VB is also in software development group. Though software can also be made using the web programming languages also.

PHP in Different Aspects

PHP is considered now-a-days to be a web programming language though everything can be done using PHP. By d way PHP is evolved formerly as a web programming language but now-a-days PHP 6 is considered to be the all in one Programming Language. Everything can be done using PHP. But it requires some extended classes and library functions and somehow extensions and modules.

PHP Frameworks

This is the most widely used term for PHP. PHP Frameworks are totally developed in PHP and developers created some extended classes and libraries to take PHP to the ultimate level. If we consider design patterns (Software Design Patterns) like MVC (Model-View-Controller), UML Diagram etc., and then these patterns can be implemented in the web application development field. And if we consider for software development, then the PHP-GTK is widely used. PHP-GTK (Gimp Tool Kit) is an extended PHP extension for software development as well as desktop application development. Even there are many frameworks like Joomla, Drupal, XOOPS, phpBB, WordPress etc. But these are on base of web application development. These require the knowledge of Object oriented programming in PHP.

Global Utilization

Now-a-days in the global market two sectors are grown in wide large range. They are Application development and web related field. And PHP covers this range. Even if we consider the network programming as well as socket programming, then PHP takes its hand up for attending. Even networking protocols can also be designed using PHP. But it requires socket extension support. Even if we consider the social networking aspect in this world like Facebook, hi5, MySpace then PHP takes the opportunity to say that it leads. But PHP is a server side scripting language and so every script must run in the server and then result will be displayed to the client. So, how can it be possible to develop desktop application? Here comes the concept of client side scripting property of PHP. PHP-GTK is considered to be the client side programming language.

In Brief, the TOP 5 Sides:

Web Application Framework based on application design patterns

Network or Socket Programming

Web Application Development

PHP comprises many in-built functions to take the load off the programmer

Desktop Application Development in the concept of Client Side Scripting.

Bounceweb has cheap and exciting offers on PHP hosting!


Creating modules with Drupal

June 24th, 2010 | Posted under Software, Web Hosting, Web Hosting Tips | 1 Comment »

Creating modules with Drupal

In Drupal – one of the most popular CMS, module can be of 3 types – core modules – that come with the Drupal installation, Community modules – developed by the Open Source community for use with Drupal, and custom modules that are written by the web-designer for custom tasks in his website. Here are the basic steps to creating a module in Drupal.

Create a folder

Create a folder with the short name for your module in sites/all/modules inside your Drupal directory. For example, if the name is examplemod, create the folder sites/all/modules/examplemod.

Create .module file

Create a PHP file named examplemod.module inside the above directory. The file should have the opening “<?php” tag. The closing php tag should be avoided according to the Drupal coding standards.

Create .info file

Create a examplemodule.info file for your module, and implement the hook_help () function to provide a brief description of your module in Drupal’s help system.

Implement hook_perm() and hook_block()

Implement the hook_perm () to specify access permissions for the module and declare and generate the block content using hook_block (). Use hook_block () to make Drupal recognise the module.

Create content and set configuration file

Create a configuration page and generate page content.

BounceWeb provides irresistible offers on Drupal hosting!


Why most applications are going the open source way?

June 9th, 2010 | Posted under Internet Trends, Software | No Comments »

Why most applications are going the open source way?

Till the last decade, most software applications that were created were proprietary products, and the source code behind the software was visible only to the core group of developers. However, the recent trend is to declare the software as open source, and let the source code open for all. Licenses like GPL (General Public License), Apache License, PHP license have come up which allow people to modify codes for their benefit. Let’s look at the reasons why open source is becoming so popular:

A large community of developers

There is a huge community of open source developers who work upon the source code to make it better, or to add new features to it, thus saving the cost of maintaining a paid workforce of developers.

Software can be modified and redistributed

For developers, it is a great platform as they can work upon the live code, modify it and redistribute it without any copyright issues.

The redistributed software retains credit of the original software

The modified and redistributed software would also have to be an open source software, and give due credit to the original product. Therefore, even though there would be different versions and modifications, the software does not lose its identity.


What makes a good web hosting service?

June 9th, 2010 | Posted under Content Management Systems, Web Hosting, Web Hosting Tips | No Comments »

What makes a good web hosting service?

There are plenty of web hosting services available in the market in different packages. While some of them offer free service, others need you to pay fees for their web hosting service. However, one needs to zero-in on one of these service providers based on a few criteria. But, what criteria can decide a good hosting service from a bad one? Here are some of the points that a good host should fulfill

It should provide reliability and have maximum uptime

Uptime is the percentage of total hours the server is accessible in the Internet. It indicates the performance of the hosting server.

Compatibility with most web components

Scripting languages like PHP, Perl; databases like MySQL, mSQL and framework like Ruby-on-Rails must be supported by the hosting server.

Interface for managing the server and database

An easy-to-use interface that helps in accessing, modifying and viewing of server files and database, like cPanel should be provided.

Excellent customer-support

They should provide support to their customers 24 x 7, and be competent to handle all kinds of issues.

Support for content management systems (CMS)

Modern content management systems like Drupal and Joomla should be supported in order to facilitate users who are comfortable in using them.


BounceWeb provides web hosting service that meets all the above criteria.


Five reasons why you should go for Linux based web hosting!

June 6th, 2010 | Posted under Web Hosting, Web Hosting Tips | No Comments »

Five reasons why you should go for Linux based web hosting!

In most cases, the criteria for choosing a good web hosting service is based on the space it provides, the speed, uptime guarantee and number of mailboxes. However, what most of us miss is what operating system is used by the web hosting server. This decision generally differs from website to website, depending on the requirements. The most popular of them is however the Linux based web hosting, due to its reliability and flawless security!

Here, we give you five most irresistible reasons why you should opt for Linux based hosting

It’s a free and open source product

There is no licensing fees, or fears of copyright issues. You can download files, use them and modify them according to your requirements.

Linux is stable and secure

It is compact file system would never let you down and most Linux-based servers run without any server glitches.

It is compatible with most databases, scripting softwares

Web scripting languages like PHP, Python and Perl; and databases like MySQL, PostgreSQL and mSQL are supported by Linux.

Linux gives you unmatched flexibility and interoperability

There is always a possibility of communicating with servers that do not operate on Linux. Even in those cases, Linux throws up no issues.

It is extremely cost-effective

It is available free of cost, so are most of the application programs required for server maintenance. Therefore, the total cost of running a web hosting service is severely reduced.

BounceWeb provides extremely reliable Linux based Web hosting.


Simple steps to create a login form

June 6th, 2010 | Posted under Software, The Internet, Web Design Tutorials | No Comments »

Simple steps to create a login form

Most websites require visitors to register themselves and login time and again to access user-specific content. This is a great tool way to interact with the visitors and provide meaningful service to the customers. However, the login system is extremely easy to implement if it is created by using PHP and MySQL. Here are some easy steps through which you can create the login system

Connect to the database

The first step is to connect to the database that has the login information such as the username, password, etc. The following codes help in connecting to a database

$connection = mysql_connect (hostname, username, password)

mysql_select_db(database name);

Store the user provided data

The data provided by the user must be stored in the form of variables so that it can be checked with the database

$username = $_POST[‘uname’];

$password = $_POST[‘password’];

Check the data with the database

These stored variables would be now checked with the existing database. If there is a single match, then the user exists, and would be redirected to his specific page

$result = mysql_query(“SELECT * FROM table name WHERE username==’$username’ AND password==’$password’”);

if(mysql_num_rows($result)==1

{

//redirect to user page

}

else

{

echo (“Invalid login credentials!”);

}

Thus, one can easily let valid users in their specific website area and refuse access to the unknown ones!

BounceWeb provides fast, and reliable PHP-MySQL hosting.


Previous Entries