Jesin's Blog

Welcome to the Portal of Technology

  • Facebook
  • GitHub
  • RSS
  • Twitter
  • Home
  • Categories
    • Domains
    • Linux
    • Networking
    • PHP
    • Virtualization
    • Web Design
    • Web Servers
    • Windows
  • WordPress Plugins
    • Custom Error Pages
    • HTTP Digest Authentication
    • Mailgun Email Validator
  • Toolbox
    • DNS Lookup Tool
    • htdigest Generator Tool Online
    • htpasswd Generator Tool Online
    • HTTP Headers Lookup Tool
    • MD5 Encryption Tool
    • Open Port Check Tool
    • SHA-1 Encryption Tool
    • URL Encoding/Decoding Tool
  • About Me
  • Contact Me
  • Sitemap
Home ›
php

Connect PHP with MySQL

November 26, 2010 PHP Jesin A 1 Comment

connect php with mysql thumbnail

Connect PHP with MySQL database, execute queries to manipulate information and retrieve data and display it using MySQL. Connecting with a MySQL database using PHP requires the use of three functions mysql_connect() mysql_select_db() and mysql_query() In this article I’ll be explaining how to connect to a MySQL server, create a database, create a table, insert values into it and retrieve it to display it in the form of HTML tables.Continue Reading…

Tags: mysql, php

List of PHP Timezones

October 21, 2010 PHP Jesin A Leave a Comment

php category thumbnail

The timezones listed here can be used with your php.ini file or htaccess file. To learn how to change your PHP time zone setting read Setting a Timezone in PHP.

This is a complete list of PHP supported timezones taken from the official PHP websiteContinue Reading…

Tags: php, php timezone

PHP include() vs require()

October 12, 2010 PHP Jesin A 1 Comment

php category thumbnail

If there is one feature that is highly useful and used by novices and experts alike its SSI (Server Side Includes). It reduces the need to copy paste repetitive code and you get a cleaner code. PHP has two functions for including files include() and require(). There is a lot of confusion on which to use when because both of them basically perform the same function of including the specified file but the difference comes by how they handle files.Continue Reading…

Tags: include, php, require, ssi

Using Sendmail on Windows

September 25, 2010 Windows Jesin A 88 Comments

windows category thumbnail

The PHP mail function is a wonderful feature of PHP but like all good things in life this function also has many drawbacks. On a Linux  platform it requires sendmail to be installed, but coming to windows a SMTP server is needed to send email. So if you take a peak inside the php.ini file you’ll find the following line

[mail function]
; For Win32 only.
SMTP = localhost
smtp_port = 25

But the limitation here is you can only specify the SMTP server name and port, if the server requires authentication there is no provision for specifying the username and password. So unless you have a mail server configured to send local email without authentication there is no way to use the php mail() to send emails.Continue Reading…

Tags: php, sendmail

How to use custom php.ini files on shared hosting

September 22, 2010 PHP Jesin A 9 Comments

php category thumbnail

The advantages of using php with apache web server are many. The wonderful file named .htaccess makes things easier by allowing the webmaster (thats you!) to play around with many settings which would otherwise need the php.ini to be edited. This is a boon for people having their websites hosted on a shared server. Such people can’t even dream of editing the php.ini file located on their web hosting provider’s server. Thus the concept of custom php.ini was born. Webmasters who have their website hosted on a server with support for custom php.ini can create a php.ini within their directory and provide all the necessary settings they require. But custom php.ini doesn’t work out-of-the-box. This article explains how to use custom php.ini on a shared hosting server.Continue Reading…

Tags: htaccess, php

Setting a Timezone in PHP

August 29, 2010 Web Servers Jesin A 1 Comment

Using the javascript date/time function is easy because its a client-side language so it displays your system time. But its not the same case with PHP. Since its a server-side language it displays the server’s time which can be irritating because you might have your server located in another country and you might live somewhere else. But changing the timezone is just a few clicks away and whats more, you can even set different timezones for different pages/directories.Continue Reading…

Tags: htaccess, php, php timezone

  • « Previous Page
  • 1
  • 2
  • 3
  • 4
  • 5
  • Next Page »

Get a wealth of information delivered to your inbox. Subscribe and never miss a single article.

  • Tutorials and howtos
  • Code, scripts and commands
  • Online Tools

* No spam, unsubscribe anytime

Hire Me

  • SSL installation and hardening (A+ on Qualys SSL test)
  • Apache & Nginx configuration
  • Email deliverability improvement (10/10 on Mail Tester & MailGenius)
  • WordPress customization, optimization and migration
  • and much more…

    Tools

    • DNS Lookup Tool
    • htdigest Generator Tool Online
    • htpasswd Generator Tool Online
    • HTTP Headers Lookup Tool
    • MD5 Encryption Tool
    • Open Port Check Tool
    • SHA-1 Encryption Tool
    • URL Encoding/Decoding Tool

    Nav

    • Home
    • About Me
    • Contact Me
    • Privacy Policy
    • Sitemap
    Vultr SSD VPS

    Creative Commons License
    Jesin's Blog by Jesin A is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.
    Based on a work at websistent.com.