Entries Tagged as ''

jCalendar: A jQuery Based Calendar Goes The Drupal Way for date type fields jstools drupal5

Jscalender module come with Jstools package in drupal 5 you can download drupal jstools package from the drupal.org site.Jscalender uses the jsCalendar javascript library, like using a special CSS class called via #attribute in the form element array to convert textfields into jcalendar enabled.

The jcalendar module uses hook_form_alter() to look for textfields with the add-jcalendar class, I had to use something different than jcalendar which is used later on the generated form elements by the jQuery code.

This is a sample of how to enable jcalendar from one of your textfields once you’ve installed the module:

To include a jscalendar popup with a textfield, just add the class ‘jscalendar’:(from readme.txt)

$form['date'] = array(
‘#type’ => ‘textfield’,
‘#attributes’ => array(’class’ => ‘jscalendar’),
);

To change the default display and functionality of the calendar, set startup
parameters by adding selectors to your element. The three configurable options
are ‘ifFormat’ (the format of the date/time written to the text field),
’showsTime’ (boolean: should time be displayed on the calendar), and
‘timeFormat’ (values of ‘12′ for 12-hour clock, which is the default, or ‘24′
for 24-hour clock).

Example:
$form['date'] = array(
‘#type’ => ‘textfield’,
‘#attributes’ => array(’class’ => ‘jscalendar’),
// Use only year, month, and day in textfield.
‘#jscalendar_ifFormat’ => ‘%Y-%m-%d’,
// Don’t show time.
‘#jscalendar_showsTime’ => ‘false’,
// Show 24-hour clock.
‘#jscalendar_timeFormat’ => ‘24′,
);

$form['firstdate'] = array(
‘#type’ => ‘textfield’,
‘#title’ => ‘The first date’,
‘#default_value’ => ‘2007-09-29′,
‘#weight’ => -20,
‘#attributes’ => array(’class’ => ‘add-jscalendar’),
‘#description’ => t(’YYYY-MM-DD’),
);

The #jcalendar_year_range custom property allows you to provide a range of years, look at the associative array $years, to show in the calendar. If the property is not passed jcalendar.module defaults to the current year plus 20.

#jcalendar_plot_dates, which is not working yet, should allow passing an array of dates to the calendar to plot. I’m not sure if this should be the job of the Drupal module or jCalendar’s jQuery code.

This first version of jcalendar.module works, it converts your textfield to three select boxes, day, month, year, and a nice table based date picker, easy to theme via CSS, and once you have the right date you can do whatever you want with it. The original textfield is removed later so your form validation and processing functions should consider if jcalendar is enabled (a simple if (module_exists(’jcalendar’))) to handle form elements in a different way.


ALTER table command mysql sql database manipulation adding new column drop column index consrtaint

Definition And Explaination:-
ALTER TABLE allows you to change the structure of an existing table. For example, you can add or delete columns, create indexes, change the type of existing columns, or rename columns or the table itself.You can use ALTER TABLE to modify the structure of a table that has not been added to a database.Alter table command allows
* To add the field;
* To delete the field out;
* To change the DEFAULT value for any of the field;
* To add or delete the table PRIMARY KEY;
* To add or delete the table FOREIGN KEY;
* To add or delete UNIQUE constraint;
* To add or delete CHECK constraint;
* To rename fields or table itself;
* To change field type.

Syntax And Structure:-

ADD [ COLUMN ]   column_definition
|    ADD [ COLUMN ] ( column_definition [,   column_definition ... ] )

|    ADD   table_constraint_definition
|    ADD ( table_constraint_definition [, table_constraint_definition ... ] )

|    ALTER [ COLUMN ] column_name  < SET DEFAULT default_option | DROP DEFAULT>
|    DROP  [ COLUMN ] column_name [ drop_behavior ]
|    DROP PRIMARY KEY
|    DROP INDEX index_name
|    DROP CONSTRAINT IDENT

|    CHANGE [ COLUMN ] old_col_name column_definition
|    MODIFY [ COLUMN ] column_definition
|    RENAME [ AS ] table_name

Examples:-

ALTER TABLE customers ADD CONTACT_PHONE VARCHAR(30)

ALTER TABLE customers ADD COLUMN CONTACT_PHONE VARCHAR(30)

ALTER TABLE customers DROP contact_name

ALTER TABLE Person CHANGE LastName Surnname String ( 40 )

ALTER TABLE Person MODIFY  Surnname String ( 30 )

ALTER TABLE offices ADD CONSTRAINT inregion  FOREIGN KEY ( region ) REFERENCES regions

ALTER TABLE salesreps DROP CONSTRAINT worksin

ALTER TABLE Customer ADD COLUMN Fax2 c(20) NOT NULL


phonebook example in php mysql insert delete confirm basic demo

This is a very basic example of php/mysql.We used to make use of mysql database and a php file for getting this done.To run this code you can first create database as provided in sql here and after creating database run this code.Make modifications as you want to do in it.

<html>
<head>
<title>Phone Book Example</title>
</head>
<body bgcolor=”#f6f6f6″ style=”font-family:arial”>
<marquee behavior=”alternate”>
<font size=’7′>Welcome to Phone Book Demo</font>
</marquee>
<br/><hr/><br/>

<table border=”1″ align=”center” width=”100%”>
<tr>
<td>
<h2 align=”center”>Enter Details</h2>
<table border=”1″ align=”center”>
<form action=”phonebookDemo.php” method=”post”>
<tr><td>First Name:</td><td><input type=”text” name=”FirstName” /></td></tr>
<tr><td>Last Name:</td><td><input type=”text” name=”LastName” /></td></tr>
<tr><td>Phone Number:</td><td><input type=”text” name=”PhoneNumber” /></td></tr>
<tr><td colspan=”2″ align=”center”><input type=”submit” value=”Add Contact” /></td></tr>
</form>
</table>
</td>
<td>
<?php
//Connectivity with MySql
$con=mysql_connect(”localhost”,”root”,”");
if(!$con)
{
echo “You are unable to connect with server</br>”;
die(”Error : “.mysql_error());
}
//Connectivity with database in MySql.
mysql_select_db(”phonebook”,$con);

$firstname = $_REQUEST['FirstName'];
$lastname = $_REQUEST['LastName'];
$phone      = $_REQUEST['PhoneNumber'];
if($firstname  != “” )
{
@mysql_query(”INSERT INTO contacts (FirstName,LastName,PhoneNumber) VALUES(’”.mysql_escape_string($firstname).”‘, ‘”.mysql_escape_string($lastname).”‘, ‘”.mysql_escape_string($phone).”‘)”);
$msg=”Record Added in phonebook”;
}
if($_REQUEST['action']==”del”)
{
@mysql_query(”DELETE FROM contacts WHERE id=”.intval($_REQUEST['id']).”;”);
}
$result = mysql_query(”SELECT * FROM contacts”);
echo “<table border=’1′ align=’center’ cellpadding=’5′>”;
echo “<tr><th>First Name</th>
<th>Last Name</th>
<th>Phone Number</th>
<th>Action</th>”;
if(!mysql_num_rows($result))echo “<tr><td colspan=4>No entry in phonebook</td></tr>”;
if($result)
{
while($row = mysql_fetch_array($result))
{
echo “<tr>”;
echo “<td>”.$row['FirstName'].”</td>”;
echo “<td>”.$row['LastName'].”</td>”;
echo “<td>”.$row['PhoneNumber'].”</td>”;
echo “<td><a onclick=\”return confirm(’Are u sure to delete this entry?’);\” href=’phonebookDemo.php?action=del&id=”.$row['id'].”‘>Delete</a></td>”;
echo “</tr>”;
}
}
echo “</table>”;

//mysql_query(”DELETE FROM contacts WHERE FirstName=’Kuldeep’”);
mysql_query($sql,$con);
mysql_close($con);

?>
</td>
</tr>
</table>
</body>
</html>

SQl for This exampple:-


CREATE TABLE `contacts` (
  `id` int(10) NOT NULL auto_increment,
  `FirstName` varchar(200) NOT NULL,
  `LastName` varchar(200) NOT NULL,
  `PhoneNumber` varchar(200) NOT NULL,
  PRIMARY KEY  (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1 AUTO_INCREMENT=6 ;

–
– Dumping data for table `contacts`
– 

INSERT INTO `contacts` (`id`, `FirstName`, `LastName`, `PhoneNumber`) VALUES (3, ‘Inder’, ‘Singh’, ‘98726-82279′),
(5, ‘Inderweb’, ‘India’, ‘98726-82279′);

—–Demo provided by KK BHARDWAJ -HP


Preventing MySQL Injection attacks with good PHP code- Using PHP for preventing MySQL injection attacks on your site

A Mysql injection is attack tried by site visitors/users to get/damage data in databases by taking benefit from poor programming of websites.An injection attack occurs when a visitor to your site types something into a form input with the purpose of changing the outcome of your MySQL query. For example, at a login screen someone may try this type of attack to gain access to a secure area of the website.

If your query to check the username and password entered by the user was this:

“SELECT * FROM users WHERE username = ‘”.$_POST['username'].”‘ AND password = ‘”.$_POST['password'].”‘”

Someone could login by using any username and for the password they would type ‘ OR ”=” which would be placed into your MySQL query changing it to be:

“SELECT * FROM users WHERE username = ‘anyuser’ AND password = ” OR ”=””

As you can see, MySQL injection attacks can be pretty serious depending on the information the person has access to once they are logged in. It is very important for you to secure your site against injection attacks. Luckily, PHP can aid you in preventing injection attacks.

MySQL will then return all the rows in the table and then, depending on your script’s logic, you will probably log them in because there was a match. Now, in most cases, people have magic_quotes_gpc turned on (it’s the PHP default) which will add backslashes to escape all ‘ (single-quote), ” (double quote), (backslash) and NULL characters. This is not foolproof though because there are other characters that should be escaped to be safe.

Preventing Mysql/PHP injections:-

There are php mysql functions to prevent such type of things:
into your queries. One of The function is mysql_real_escape_string().

use Like :- $value = “‘” . mysql_real_escape_string($value) . “‘”;

For integer values dont forgot to use intval() function


configuring mysql after installation installing mysql linux apache

1. Admin user id: root
Default password: blank

The first task is to assign a password:

[prompt]$ mysqladmin -u root password ‘new-password’

Note: the following SQL commands will also work:

mysql> USE mysql;
mysql> UPDATE user SET Password=PASSWORD(’new-password’) WHERE user=’root’;
mysql> FLUSH PRIVILEGES;

2. Create a database: (Creates directory /var/lib/mysql/bedrock)

[prompt]$ mysqladmin -h localhost -u root -ppassword create bedrock

(or use SQL command: CREATE DATABASE bedrock;)

3. Add tables, data, etc:
Connect to database and issue the following SQL commands:

[prompt]$ mysql -h localhost -u root -ppassword

mysql> use bedrock;                - Define database to connect to. Refers to directory path: /var/lib/mysql/bedrock
mysql> create table employee (Name char(20),Dept char(20),jobTitle char(20));
mysql> DESCRIBE employee;       - View the table just created. Same as “show columns from employee;”
+———-+———-+——+—–+———+——-+
| Field    | Type     | Null | Key | Default | Extra |
+———-+———-+——+—–+———+——-+
| Name     | char(20) | YES  |     | NULL    |       |
| Dept     | char(20) | YES  |     | NULL    |       |
| jobTitle | char(20) | YES  |     | NULL    |       |
+———-+———-+——+—–+———+——-+
3 rows in set (0.03 sec)

mysql> show tables;
+——————-+
| Tables_in_bedrock |
+——————-+
| employee          |
+——————-+

mysql> INSERT INTO employee VALUES (’Fred Flinstone’,'Quarry Worker’,'Rock Digger’);
mysql> INSERT INTO employee VALUES (’Wilma Flinstone’,'Finance’,'Analyst’);
mysql> INSERT into employee values (’Barney Rubble’,'Sales’,'Neighbor’);
mysql> INSERT INTO employee VALUES (’Betty Rubble’,'IT’,'Neighbor’);

Note: Data type used was CHAR. Other data types include:
* CHAR(M) : Fixed length string. Always stores M characters whether it is holding 2 or 20 characters. Where M can range 1 to 255 characters.
* VARCHAR(M) : Variable length. Stores only the string. If M is defined to be 200 but the string is 20 characters long, only 20 characters are stored. Slower than CHAR.
* INT : Ranging from -2147483648 to 2147483647 or unsigned 0 to 4294967295
* FLOAT(M,N) : FLOAT(4,2) - Four digits total of which 2 are after the decimal. i.e. 12.34 Values are rounded to fit format if they are too large.
* DATE, TEXT, BLOB, SET, ENUM

4. Add a user. Use the MySQL SQL console to enter SQL commands. The command mysql with the correct login/password will connect you to the database. The admin tables are stored in the database “mysql”.

[prompt]$ mysql -h localhost -u root -ppassword
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 1 to server version: 3.23.41

Type ‘help;’ or ‘\h’ for help. Type ‘\c’ to clear the buffer.

mysql> USE mysql;
mysql> SHOW TABLES;
+—————–+
| Tables_in_mysql |
+—————–+
| columns_priv    |
| db              |
| func            |
| host            |
| tables_priv     |
| user            |
+—————–+
mysql> INSERT INTO user (Host, User, Password, Select_priv) VALUES (”, ‘Dude1′, password(’supersecret’), ‘Y’);
mysql> FLUSH PRIVILEGES;   - Required each time one makes a change to the GRANT table
mysql> GRANT ALL PRIVILEGES ON bedrock.* TO Dude1;
mysql> FLUSH PRIVILEGES;   - Required each time one makes a change to the GRANT table
mysql> quit

Note:
* There is NO space between the -p and the password! You can omit the password and you will be prompted for it.
* The SQL flush command is equivalent to issuing the command:

[prompt]$ mysqladmin reload

5. Test the database:

mysql> SELECT * from employee;
+—————–+—————+————-+
| Name            | Dept          | jobTitle    |
+—————–+—————+————-+
| Fred Flinstone  | Quarry Worker | Rock Digger |
| Wilma Flinstone | Finance       | Analyst     |
| Barney Rubble   | Sales         | Neighbor    |
| Betty Rubble    | IT            | Neighbor    |
+—————–+—————+————-+
1 row in set (0.00 sec)

mysql> SELECT name FROM employee WHERE dept=’Sales’;
+—————+
| name          |
+—————+
| Barney Rubble |
+—————+
1 row in set (0.00 sec)

6. Quit from the SQL shell:

[prompt]$ quit

7. Shutting down the database:

[prompt]$ mysqladmin -u root -ppassword shutdown       - PREFERRED
OR
[prompt]$ /etc/rc.d/init.d/mysqld stop
OR
[prompt]$ service mysqld stop


jquery quick tips to replace javascript code from file learn jquery

The jquery is a simple and quick to use javascript library and provides a
rich set of functionality in just few lines of code.The $ symbol is also set up as
a shortcut for jQuery.If you want the convenience of the $ function for jQuery without colliding with some other use of the global $ function, the jQuery documentation suggests the following idiom:

(function($) {
    // Within this block, $ is a reference to jQuery
    // Neat, and clean
})(jQuery);

Referring elements of document in jquery code.
jQuery(’div.panel’)
    All divs with class=“panel”
jQuery(’p#intro’)
    The paragraph with id=“intro”
jQuery(’div#content a:visible’)
    All visible links inside the div with id=“content”
jQuery(’input[@name=email]‘)
    All input fields with name=“email”
jQuery(’table.orders tr:odd’)
    “odd” numbered rows in a table with class “orders”
jQuery(’a[@href^="http://"]‘)
    All external links (links that start with http://)
jQuery(’p[a]‘)
    All paragraphs that contain one or more links  if (t.val() == title) {
              t.val();
              t.removeClass(‘blur’);

$(‘input:text).hint();

var title = t.attr(‘title’);
    // only apply logic if the element has the attribute
    if (title) {
      // on blur, set value to title attr if text is blank
      t.blur(function (){
        if (t.val() == ) {
          t.val(title);
          t.addClass(‘blur’);
        }
      });
      // on focus, set value to blank if current value 
      // matches title attr
      t.focus(function (){
        if (t.val() == title) {
          t.val();
          t.removeClass(‘blur’);
        }
      });
t.parents(‘form:first()’).submit(function(){
  if (t.val() == title) {
    t.val();
    t.removeClass(‘blur’);
  }
})

$(‘#search, #username, input.hint’).hint(); // etc
 <!--adsensestart-->

Configuration Directives in httpd.conf /etc/httpd/conf/httpd.conf linux apache serevr

You can configure apache server from /etc/httpd/conf/httpd.conf.

Before editing httpd.conf, first make a copy the original file. Creating a backup makes it easier to recover from mistakes made while editing the configuration file.

If configuring the Apache HTTP Server, edit /etc/httpd/conf/httpd.conf and then either reload, restart, or stop and start the httpd process as outlined in Section 10.4 Starting and Stopping httpd.

If a mistake is made and the Web server does not work correctly, first review recently edited passages in httpd.conf to verify there are no typos.

Next look in the Web server’s error log, /var/log/httpd/error_log. The error log may not be easy to interpret, depending on the level of experience. If experiencing problems, however, the last entries in the error log should provide useful information about what happened.

Next are a list of short descriptions for many of the directives included in httpd.conf. These descriptions are not exhaustive. For more information, refer to the Apache documentation provided in HTML format at http://localhost/manual/ or online at the following URL: http://httpd.apache.org/docs-2.0/.

For more information about mod_ssl directives, refer to the documentation included in HTML format at http://localhost/mod/mod_ssl.html or online at the following URL: http://httpd.apache.org/docs-2.0/mod/mod_ssl.html.<!–adsencestart–>


FTP (File Transfer Protocol) clients filezilla smartftp freeftp autoftp

 FTP (File Transfer Protocol) allows a person to transfer files between two computers,
generally connected via the Internet. If your system has FTP and is connected to the Internet,
you can access very large amounts of files available on a great number of computer systems.
If you are on Bitnet or a UUCP host, you should look for servers that work through electronic
mail (e-mail). A good source of information on archives in general, is the Usenet newsgroup comp.archives.
When using FTP, you use a program, called a 'client' to connect to a machine that holds the files, a 'server'.
  • FTP (File Transfer Protocol) is the simplest and most secure way to exchange files over the Internet. Whether you know it or not, you most likely use FTP all the time.
  • The most common use for FTP is to download files from the Internet. Because of this, FTP is the backbone of the MP3 music craze, and vital to most online auction and game enthusiasts. In addition, the ability to transfer files back-and-forth makes FTP essential for anyone creating a Web page, amateurs and professionals alike.
  • When downloading a file from the Internet you’re actually transferring the file to your computer from another computer over the Internet. This is why the T (transfer) is in FTP. You may not know where the computer is that the file is coming from but you most likely know it’s URL or Internet address.
  • An FTP address looks a lot like an HTTP, or Website, address except it uses the prefix ftp:// instead of http://.
FTP CLients:-
There are many ftp clients
  • FileZilla Client (also referred to as FileZilla) is a free, open source, cross-platform FTP client. Binaries are available for Windows, Linux, and Mac OS X. It supports FTP, SFTP, and FTPS (FTP over SSL/TLS). As of June 20, 2008, it was the 10th most popular download of all time from SourceForge.net.FileZilla Server is a sister product of FileZilla Client. It is an FTP server supported by the same project and features support for FTP and FTP over SSL/TLS.FileZilla’s source code is hosted on SourceForge. The project was featured as Project of the Month in November 2003.
  • What is SmartFTP?( SMARTFTP)

    SmartFTP is an FTP (File Transfer Protocol) client which allows you to transfer files between your local computer and a server on the Internet. With its many basic and advanced features SmartFTP also offers secure, reliable and efficient transfers that make it a powerful tool. Click here to Download our ftp software.

    • Windows XP / IE like user interface. XP Theme Support SSL (Implicit/Explicit), Drag & Drop within internal windows and from Explorer, Multi Connections (remote and local), FXP support and more. Free for personal use. (5.2MB)

      HOMEPAGE | | DOWNLOAD added Jun 6 ‘02

  • WS_FTP LE

    Free for non-commercial use. The best FTP client on the market. I use it to upload my pages. (547KB)

    DOWNLOAD updated Mar 30


    AUTO FTP

    Another good FTP client. The free one is ad supported. (1.3MB)

    DOWNLOAD updated June 3


    WAR FTP BETA

    The only battles you’ll have is which FTP client to use. Another FTP client. (1.21MB)

    DOWNLOAD


    W3FILER

    Standard features. Upload, download. You know the routine. (809KB)

    DOWNLOAD added Sept 1


    FREEFTP

    Just drag and drop your files to and from the ftp sites. Multiple drag & drop file transfers. (1.4MB)

    HOMEPAGE | | DOWNLOAD added Oct 22 ‘00


    FUNFTP

    Fun ftp is an ftp program that supports multiple languages and skins. (920KB)

    DOWNLOAD added Oct 30 ‘00



    FTP PASSWORD RECOVERY

    FTP Password Recovery emulates a local FTP server and thereby allows you to recover the FTP login password for any FTP account you may have, as long as it is cached inside an FTP client program. FTP passwords are commonly cached by FTP programs (WSFTP, CuteFTP etc.), so you don’t have to enter them each time, but they are usually masked by asterisk or not shown at all. To recover those passwords, you can use the client, that holds the cached password, and connect to FTP Password Recovery, which will then reveal the password it receives from the FTP program. The program can only recover the passwords that are stored on your computer. (9KB)

    HOMEPAGE | | DOWNLOAD updated Feb 10 ‘04


    RIGHT FTP

    RightFTP features: multi-threaded data transfers, firewall support, ability to change remote file/directory attributes, passive data transfer and more. (768KB)

    HOMEPAGE | | DOWNLOAD added Dec 2 ‘02


    CORE FTP

    FTP Client with SSL/TLS, site to site transfers, drag & drop browser integration, and many other advanced features. Free for non-commercial use. (1.5MB)

    HOMEPAGE | | DOWNLOAD updated Apr 30 ‘08


    FILEZILLA

    FileZilla is a fast FTP client for Windows with a lot of features. FileZilla Server is a reliable FTP server. (1.9MB)

    HOMEPAGE | | DOWNLOAD updated Jul 3 ‘06


    JFTP

    JFTP is written entirely in Java. Graphical FTP (File Transfer Protocol) client application for transferring files between your PC and an FTP site. Requires JVM installed on your computer. (3MB)

    HOMEPAGE | | DOWNLOAD updated Apr 10 ‘04


    BLADE FTP

    It allows you browse several FTP site at the same time, you can also create a task and add the files into it, the task can execute automatically, it makes the updating and backuping very easy. Another new feature is History Manage, it can record the detail of uploading and downloading every time, when you are going to update your web site, you can re-execute the history simply. (2MB)

    HOMEPAGE | | DOWNLOAD updated Aug 15 ‘05


    RCFTP

    With rcFTP you can rightclick on any file in your Windows Explorer, and choose Send To - Upload with rcFTP. It works fast and easy, without the need of a full blown FTP client like WS_FTP. It supports multiple file selections. (200KB)

    HOMEPAGE | | DOWNLOAD added Aug 25 ‘04


    WINSCP

    Its main function is the secure file transfer between a local and a remote computer. Beyond this, WinSCP offers basic file manager functionality. It uses Secure Shell (SSH) and supports, in addition to Secure FTP, also legacy SCP protocol. (1.4MB)

    HOMEPAGE | | DOWNLOAD added May 31 ‘05


    ACEFTP 3

    Ability to store and configure your connections using the explorer-style advanced site management. Ability to make server-to-server file transfers. Ability to open several FTP sites easily. Ability to execute multiple file transfers concurrently. (3MB)

    HOMEPAGE | | DOWNLOAD added April 26 ‘06


    CROSS FTP

    CrossFTP is a versatile, user friendly GUI FTP client for multiple-platforms. Offers daily functionalities for general FTP tasks. Java based. (927KB)

    HOMEPAGE | | DOWNLOAD added Mar 8 ‘07


    STAFF-FTP

    FTP-Client with unique features (ftp, fxp, tls, ssl, full glftpd support…). (1.6MB)

    HOMEPAGE | | DOWNLOAD added May 2 ‘07


    RED DRIVE FILE TRANSFER

    Red Drive is a free file transfer extension that integrates with your Windows Explorer environment allowing you to drag, drop, open and edit files on remote servers without launching a separate file transfer client. Red Drive supports various file transfer protocols including FTP, FTPS (FTP over SSL), SFTP (FTP over SSH) and WebDAV. (914KB)

    HOMEPAGE | | DOWNLOAD added Aug 25 ‘07


    ALFTP

    The convenient Client Explorer and Server Explorer in ALFTP have easy to use “tree views” so you can browse, move, and transfer files on FTP servers just like you already do on your own PC. Free for non-commercial use. (6.5MB)

    HOMEPAGE | | DOWNLOAD added Oct 28 ‘07


    M2FTP

    m2ftp is a so-called FTP-client - a software which is used to establish a connection to an FTP-server. m2ftp can be used to easily up and download as well as administer data files and directories, without users having to know the functionalities of FTP (File Transfer Protocol). Free for non-commercial use. (5.4MB)

    HOMEPAGE | | DOWNLOAD added Mar 10 ‘08


connecting to Mysql using ODBC windows drivers within ASP code file

Many times in ASP or dot net we may need to connect to a mysql database.For making a connection to mysql database we need to install mysql connector for windows which you can download from:-

http://dev.mysql.com/get/Downloads/Connector-ODBC/5.1/mysql-connector-odbc-5.1.5-win32.msi/from/pick?file=Downloads/Connector-ODBC/5.1/mysql-connector-odbc-5.1.5-win32.msi&mirror=pick&file=Downloads/Connector-ODBC/5.1/mysql-connector-odbc-5.1.5-win32.msi&mirror=pick

After downloading this connector just install it.and follow the instructions at mysql site:-
http://dev.mysql.com/doc/refman/5.0/en/connector-odbc-configuration-dsn-windows.html

So all is done…

enjoy mysql databases in ASP code file now :)


log in mysql from command prompt windows to access database and change passwords grant privialiges Create users

First of all you should know  how you can add users in mysql databases:-

  • Using CREATE USER and/or GRANT commands
  • Inserting a new record into the mysql.user table

First let’s see how to use the CREATE USER command:-

     CREATE USER user [IDENTIFIED BY [PASSWORD] ‘password‘]

e.g

mysql>CREATE USER ‘myuser’@‘localhost’ IDENTIFIED BY ‘mypassword’;
Once user added in databases you need to provide privileges to that user.You can use like:-

mysql>GRANT SELECT,INSERT,UPDATE,DELETE ON *.* TO myuser@‘localhost’;
or mysql>GRANT ALL ON *.* TO ‘myuser’@‘localhost’;

Another way for creating users in mysql is just enter directoly in user table of mysql and make few entries:-
mysql> INSERT INTO user VALUES('localhost','monty',PASSWORD('some_pass'),
     'Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y');
or
mysql> INSERT INTO user (Host,User,Password) VALUES('localhost','usename','pass');
mysql> FLUSH PRIVILEGES;