wildteen88
Staff Alumni-
Posts
10,480 -
Joined
-
Last visited
Never
Everything posted by wildteen88
-
[quote author=Switch0r link=topic=111761.msg459429#msg459429 date=1162118216] try this: http://vertrigo.sourceforge.net/ no hassle to install/setup, plus its an all in one install package, me loves it :) [/quote] I forbid those all-in-one setups. I prefer to manually install Apache and PHP. If you want to install Apache and PHP then have a read of [url=http://www.phpfreaks.com/forums/index.php/topic,108327.msg435982.html#msg435982]this post of mine[/url].
-
The location of the php.ini can be found by running a function call phpinfo() in php script and looking at the line that starts with [b]Configuration File (php.ini) Path[/b]. To the right of that line it'll show you the full path to the php.ino. If you are looking to edit this file then you'll need to check with your host whether you have access to this file. Most shared hosts prevent users from editing the php.ini however sometimes they do allow you to use a custom php.ini agin you'll need to check with your host on this one. If you are not allowed access to the php.ini then they only way you change the php settings is by addinga php_flag/value to a .htaccess file to change a certain setting. Such as turning on display_errors: [code]php_flag display_errors On[/code] However not all PHP settings can be changed via a .htaccess file. Another option is use the ini_set() function which you can add to your PHP scripts to temporarily change a PHP setting for your script. Again this function can only change a few PHP settings. You don't have to protect your PHP files that have your mysql login credentials as no one can see the actual source code of these files from a web browser, you'll only see the output from these files. However if you store your private login details in files that don't have a php extension then anyone can view the contents of the file. For renaming admin.php I'd recommend thorpe's suggestion of asking it on the php-nuke support site or asking in our Third Party PHP Scripts forum.
-
I had a little play and came up with [url=http://homepage.ntlworld.com/cshepwood/Solarpitch/test.html]this[/url] That is as close as I could get it to the bottom image. You can use the code if you wish.
-
PHP - MySQL - IIS XPP issue
wildteen88 replied to Ting's topic in PHP Installation and Configuration
Your script requires the standard MySQL Library (php_mysql.dll) not the MySQL Improved Library (php_mysql[b]i[/b].dll (note the i after' mysql' and before '.dll'). So enable extension=php_mysql.dll from within the php.ini. Restart your server. The MySQL Improved Library has a completely different function library. Also You don't need to enable the MySQL Improved Library if you have MySQL5 installed. -
Try this: "DELETE FROM news, news_comments WHERE news.id='$id' AND news_comments.news_id='$id'"
-
When creating an Alias you need to setup an Alias using the Alias directive, which you have done. Then you need to have a corresponding directory directive, like so: <Directory "alias-path-here"> Directory saettings here </directory> For example for the tshirtshop alias you'll need this: [code]Alias /tshirtshop/ "C:/tshirtshop/" <Directory "C:/tshirtshop"> Options Indexes MultiViews AllowOverride None Order allow,deny Allow from all </Directory>[/code] Now save the httpd.conf and restart Apache. Now put your files in C:\tshirtshop and go to http://localhost/tshirtshop/ You should now see the files you have just placed in C:\tshirtshop or your index file will load up automatically.
-
The Apache module (php5apache2.dll) that comes with PHP is not compatible with Apache2.2.x. In order to use PHP with Apache2.2, ypu'll need to do one of the following: - download the latest CVS version of PHP which is PHP5.2 - download the third party Apache module from apachelounge.com, or - downgrade Apache to Apache2.0.x
-
$row[0] is created from the for loops second parameter (highlighted below): for ($count = 0; [b]$row = $results->Fetch_row();[/b] ++count) Looks like $results is a class which calls a method (function) called Fetch_row. Fetch_row returns an array of results from the query that was previously executed. $row[0] will be the first field from the table that was queried. I cant really explain it as I don't know what's going on. But I'd say that's the basics though.
-
php_in_use please do not post posts like these. This can be considered as SPAM. Please post this in your thread [url=http://www.phpfreaks.com/forums/index.php/topic,112654.0.html]here[/url]. Or post in the Misc forum.
-
navs2 is most probably an iframe/frame as you are passing a url to it.
-
help! This Account Has Exceeded Its CPU Quota!
wildteen88 replied to graphicguy's topic in PHP Coding Help
GET shouldnt be eating up your CPU. It is your PHP script that is eating up your RAM/CPU. If you are using mysql queries then that is most probably the culprit. Try and optimize your SQL Queries/database structure It doesnt matter how many GETs you use or what ever. -
Another option is to define $adminaccess as global. Change [code=php:0]global $dbc, $user_id;[/code] to [code=php:0]global $dbc, $user_id, $adminaccess;[/code] Now will be able to echo $adminaccess after you have called the displayamdinpanel function.
-
Open up Apaches error log (should be in a folder called logs in the XAMPP folder), scroll to the very bottom you should find an error message for why you are getting the 500 error message. Also make sure you have restarted Apache when you enabled mod_rewrite in the httpd.conf.
-
Mysql query only has two parameters. Your code code has three parameters. The only parameters mysql_query has is the query and the secound parameter which is optional is the link identify to the mysql connection. So this is what the line should look like: [code]$query = mysql_query ("select * from top_cats order by catname") or die (mysql_error());[/code]
-
I cannot install PHP5 with Apache 2.2...
wildteen88 replied to JP128's topic in PHP Installation and Configuration
Downgrade Apache to Apache2.0.x instead. The php5apache2.dll Apache Module is not compatible with Apache2.2.x. If you wnat to use Apache2.2.x with PHP you'll need to get the third party php45apache2.dll Apache2.2 Module from apachelounge.com -
You could enable short_open_tags by adding the following: [code]php_flag short_open_tags On[/code] to .haccess file. However I agree with thorpe using short tags is poor practice.
-
For issue #1 you need to turn your error_reporting level up to E_ALL and turn display_errors on For issue #2 it is not a stupid error. It actually an error on your part, your syntax is slightly wrong basically. With the following code: [code]if ($_GET['some_var'] == '')[/code] You are checking the $_GET['some_var'] variables value and not the existence . However if this variable does not exist then PHP will report an undefined variable/index notice (not an error). What you should do is first check for the existence of the variable and then check the value of the variable if it exists. So you'll do something like this: [code]if(isset($_GET['some_var']) && $_GET['some_var'] == '')[/code] Now when you run your script. PHP will now check for the existance of the $_GET['some_var'] variable first, then if it finds the variable it will now check the value of the variable. Whereas before you are not checking the existence of the variable and so PHP thinks this variable already exists and thus you get the undefined notice message. If(isset($var)) and if($var) are two completely different things, they are similar but they have different behaviour. For issue #3 you may need to configure PHP to use your server SMTP Server.
-
You cant view htaccess files as by default Apache denies access to files starting with .ht for security reasons. What are you trying to do? When creating a .htaccess file you don't give it a file name. Its just .htaccess nothing else. You only edit this file and then Apache reads this file automatically when going to the directory the .htaccess file is in.
-
When you got to http://localhost/tshirtshop/test.php and right click and select view source do you see your PHP coding? If you do then Apache is not setup. You need to setup Apache to parse PHP files with the PHP Interpreter. I have posted a few posts in this forum how to do this, such as [url=http://www.phpfreaks.com/forums/index.php/topic,108327.msg435982.html#msg435982]this post[/url].
-
$result does not hold the results but a result resource. A result resource points to the location in the memory where the results are stored. YOu use the result resource with othe mysql functions such as mysql_fetch_array, mysql_num_rows, mysql_result etc. What you'll want to do is to use a function called mysql_num_rows this will then return the number of rows returned from the query: [code]$pageview mysql_num_rows($result);[/code] You only use count on arrays. count then counts the number of items within the array.
-
No you don't need to uncomment/add AddModule mod_rewrite.c or ClearModuleList Just uncommend [b]LoadModule mod_rewrite modules/mod_rewrite.sop[/b] in the httpd.conf. Save and restart the Apache server. Mod_rewrite should be enabled.
-
what mysql join am i learning please cheers confused lol.
wildteen88 replied to redarrow's topic in PHP Coding Help
You're using a basic join. -
If you are enabling the exif extension then make sure you have enabled the mbstring extension (php_mbstring.dll) before you enable the exif extension So make sure [b]extension=php_mbstring.dll[/b] is before [b]extension=php_exif.dll[/b] in the php.ini and that the mbstring extension is enable too as exif requires this extension in order to function. Quoted from php.net: [quote]Windows users must enable both the php_mbstring.dll and php_exif.dll DLL's in php.ini. The php_mbstring.dll DLL must be loaded before the php_exif.dll DLL so adjust your php.ini accordingly.[/quote]
-
[quote author=php_joe link=topic=112733.msg458066#msg458066 date=1161880995] [quote author=ImJustBrndn link=topic=112733.msg457739#msg457739 date=1161823879] I'm curious as to how to hide file extensions in the browser's address bar. For example http://www.threadless.com/submit http://www.threadless.com/submit.php both take you to the same file, but if you go to the one without the .php, the .php never shows up. Can someone please tell me how to do this, I've searched and not been able to find it out. Thanks in advance guys, you rock. Brandon [/quote] For [b]http://www.threadless.com/submit[/b] you just make a folder named "submit" and then name the file index.php instead of "submit.php" Joe [/quote] Thats a long winded way of doing it! The best option is to use mod_rewrite!: [code]RewriteRule ^submit$ submit.php[/code] Then when ever you go to http://www.threadless.com/submit it'll call submit.php Another option is to tell Apache to parse extensionless files with PHP instead, which isnt recommended. mod_rewrite is the best way to go about it.
-
There is output in header.php around line 24 Post lines 20 - 28 here from header.php I guess header.php outputs HTML which shows your header graphic and stuff. This is the culprit.