wildteen88
Staff Alumni-
Posts
10,480 -
Joined
-
Last visited
Never
Everything posted by wildteen88
-
[SOLVED] error messages???
wildteen88 replied to cluce's topic in PHP Installation and Configuration
You have to edit php's configuration file (php.ini) Scroll down to line 1011, uncomment it (remove the semi-colon from in front of the line (). Then change /tmp to the actual path you want your sessions to be saved to. -
If php can't find the php.ini it will state C:\WINDOWS If php finds the php.ini in C:\WINDOWS it will show C:\WINDOWS\php.ini
-
Another way would to be to use a constructor: <?php class FilterPage { private $all; private $id; // this will get called automatically when the class is initiated. public function FilterPage() { $this->all = $_GET['all']; $this->id = $_GET['id']; } public function getpage() { if($this->all == 1) { echo "all right"; } else { echo "all wrong"; } if($this->id == 1) { echo "id right"; } else { echo "id wrong"; } echo "Nothing"; } } $_temp = new FilterPage(); echo $_temp->getpage(); ?>
-
Having to refer the mysql link resource (that is what $db holds) doesn't make the mysql improved library more secure. It just enforces people to refer the link resource within functions. This is especially good if you connect to more than 1 MySQL server. MySQLi adds more/better functionality over the standard the mysql library. It also comes with a pre-built mysql class. It does not have better security. They are both the same. Just that MySQLi allows you to work more efficiently when working with mysql databases.
-
php installation on windows.....
wildteen88 replied to k_tech's topic in PHP Installation and Configuration
WAMP is a pre-configured package which means it sets everything up for you during installation. You should not need to change anything to get it working. -
You have to save your .php files in wamps www folder (C:/wamp5/www) and then open up your desired web browser and go to http://localhost/myfile.php If you don't go to localhost then your php wont be parsed.
-
no courtesy when one responds
wildteen88 replied to suzzane2020's topic in PHPFreaks.com Website Feedback
I get it all the time! Don't know why A lot of my posts go without responses. -
all done, steel not parsing php part of code..
wildteen88 replied to clown's topic in PHP Installation and Configuration
Make sure you have removed previous configuration files, httpd.conf, php.ini etc or any left over files from your previous installation. Also make sure your files end with .php and not another extension like .html -
[SOLVED] connectivity erroe
wildteen88 replied to lunate's topic in PHP Installation and Configuration
Basically what that error is saying that Dreamweaver has failed to connect to your MySQL server due to your PHP setup, you either have not enabled the mysql extension or your php configuration doesn't allow persistent connections. Try mysql_connect instead of mysql_pconnect if you still get the same error message when you have made the changes then run a simple script with the following code in it: <?php phpinfo(); ?> Run that code and then scroll down the page and see if you can see a MySQL heading. If you can't find a mysql heading then the mysql extension hasn't been enabled. Have a read of this faq for enabling the mysql extension. -
port 3306 is to do with MySQL and not Apache/PHP. By default MySQL listens to port 3306. When uninstalling MySQL it is important that you stop the service before your uninstall it, MySQL does attempt to stop the service if its running during unistall but this sometimes fails. If you don't stop the service then it can cause these sort of problems.
-
PHP.INI proble with MYSQL no server connection blank page desplayed
wildteen88 replied to strawbilly84's topic in MySQL Help
What PHP distribution did you use when you installed PHP? Did you download the PHP installer or the zipped binaries? If you downloaded the PHP Installer and installed PHP that way, then download the zipped binaries and extract the contents of the zip to where you installed PHP. Make sure you overwrite existing files too. The installer doesn't install the same files as the zipped binary distribution. Also make sure you are using PHP5 and not PHP4. MySQL Improved is not available for PHP4. -
You do somethink like this: $myVar = $_POST['myVar']; mysql_query("INSERT INTO table_here (col1) Values ('$myVar')");
-
Just a tip: If you are getting 4GB or memory make sure you get Windows XP 64bit and not 32bit. 32bit can only "see" up to 3GB. Also I have seen a lot of people recommend C2D over AMD X2. Go for an E6300, or the E6320 (if you want more cache) and overclock the pants of it, it'll love you . C2D are so easy to OC. You can easily get 3.6Ghz out it - thats without OC'ing your ram.
-
You don't have to use a submit button if you don't want to. If you are using a link to submit the form then give the form itself a name and then use the following HTML to submit the form: <a href="javascript:void(0)" onClick="document.MYFORM.Submit();">Send Mail</a> When you click the link it will submit the form. In your code you don't check for the submit button, as you don't have one. All you do is check the required fields are filled in, such as To, Subject, From and Message for example.
-
If you don't name your form fields then the browser will use numbers as the names, for example $_POST[0] will be the first field, $_POST[1] will be the second, $_POST[2] will be the third etc. You should really name your fields, It will be a lot easier identifying where your data is coming from rather then numbers.
-
Did you restart Apache? Or what ever server software you are using. When ever you change/move configuration files you must restart your server software. I forgot to mention that in my last post.
-
PHP.INI proble with MYSQL no server connection blank page desplayed
wildteen88 replied to strawbilly84's topic in MySQL Help
Follow this FAQ. Note: That walks you through enabling the standard mysql extension. What you will want to do is use php_mysqli.dll in place of php_mysql.dll. -
Doesn't really matter. PHP4 should work with MySQL4 and 5. however most PHP4 setups I have seen use MySQL4. Its up to you.
-
Check that the mysql extension is loaded by running phpinfo() and scrolling down the page until you find a mysql section. Click the link in my sig below and read the FAQ thread titled called to undefined function mysql_connect
-
php4apache2.dll is for Apache2.0.x and not Apache2.2.x I don't think PHP4 is compatible with Apache2.2.x. Check there is a file called php4apache2_2.dll. If you can't find that file then consider downgrading Apache to Apache2.0.x instead.
-
Does a simple: <?php echo "Hello World"; ?> Work? If that doesn't work then Apache is not configured properly.
-
If PHP is reporting that then it can't find your php.ini Make sure you have renamed php.ini-recommended (which is located in PHP's installation folder) to just php.ini and that you have moved the php.ini to the WINDOWS directory. NOTE: Only move the php.ini if you have not added your PHP folder to the Windows PATH Variable.
-
Looks like you have forgotten to close a string somewhere in you code, if you look at the first code block above you will see about half way through the syntax colouring goes wrong. This is the offending line: $query = "INSERT INTO Person('FirstName', 'LastName', 'Age'); Change it to: $query = "INSERT INTO Person('FirstName', 'LastName', 'Age')"; Also it is a good idea to run display_errors on in your php.ini. If you make any changes to the php.ini make sure you restart Apache. EDIT: Ooh MadTechie beat me to it.
-
Need Help with PHP Installation
wildteen88 replied to tsugiarto's topic in PHP Installation and Configuration
Yes you must go to http://localhost in order to run your .php files. You place your .php files in Apaches htdocs folder (or the whatever you set your DocumentRoot as, default is Apaches's htdocs folder (default path: C:/Program Files/Apache Group/Apache2/htdoc)). To get PHP working with Apache you just need to add a few lines in to Apaches httpd.conf, example LoadModule php5_module "C:/php/php5apache2_2.dll" AddType application/x-httpd-php .php and that should me enough to get PHP working with Apache. The rest of the configuration is down how you want PHP to run, such as what extensions to use, whether to display syntax errors during runtime etc. You do this in PHP's configuration file called php.ini NOTE: It is important you restart Apache whenever you make any changes to the httpd.conf or php.ini. Otherwise your changes will not take affect until Apache is restarted. -
PHP.INI proble with MYSQL no server connection blank page desplayed
wildteen88 replied to strawbilly84's topic in MySQL Help
You didn't turn display_errors on in the php.ini. It is still set to off. The line you are supposed to edit is line 356 in the php.ini. By looks of it you edited line 74, which is incorrect