-
Posts
9,409 -
Joined
-
Last visited
-
Days Won
1
Everything posted by MadTechie
-
erm.. either remove the header or read the file inn, this works fine <?php function SecurityCode(){ $num = rand(1000,9999); //header ("Content-type: image/png"); $img_handle = imagecreate (50, 20); $back_color = imagecolorallocate ($img_handle, 255, 255, 255); $txt_color = imagecolorallocate ($img_handle, 233, 114, 191); imagestring ($img_handle, 31, 7, 2, $num, $txt_color); imagepng ($img_handle,"code.png"); echo "<img src='code.png'>"; } SecurityCode(); ?> also check you can write to that folder (as i had to update my access rights)
-
Update 2nd selection box based on 1st WITHOUT reloading page
MadTechie replied to Moz's topic in Javascript Help
ajax is basically javascript so no install needed, and yes post is a little long see alpines great post http://www.phpfreaks.com/forums/index.php/topic,115581.0.html -
Code from W3Schools.com does not work! WHY?????
MadTechie replied to mgs019's topic in Javascript Help
change var xmlHttpfunction showUser() to var xmlHttpfunction; function showUser() mainewoods = AJAX King -
[SOLVED] Fatal error: Call to undefined function
MadTechie replied to thomhart11's topic in PHP Coding Help
your missing the function col_one_end(); or post the connection.inc.php, inc/design.inc.php, widget/messages/singlemessage.inc.php widget/messages/editmessage.inc.php file which ever one holds that function remember remove any passwords before posting -
depends what function you are trying to do, ie sort a list etc a combo of javascript and php works well and then moving to ajax or frames
-
Is it possible are not to generate reports with php
MadTechie replied to sasi's topic in PHP Coding Help
<?php echo "report<br>"; echo "stuff"; ?> or theirs always the freelance section -
more of a HTML problem that a php one
-
oh you could try 1) Create a file called .htaccess in the same directory as your php script (this will apply to any php script that is in this directory). 2) and set "php_value max_execution_time 0" i think that works but i am no expert on .htaccess files but atleast it a directions
-
not sure myself i think set_time_limit(0) will remove timeouts
-
try increasing the 3600 to 3600000 or something,
-
Dynamic .asx and .ram playlist with .php extension
MadTechie replied to keenlearner's topic in PHP Coding Help
real one mimi is -
ok when you "Make" the file use that instead of pull from the file.. either way it was just a suggection
-
<php $x = readfile("file.html"); ?>
-
The file will exist but only you will know where.. as the file location is being pulled via the script.. if you don't want the file to exists where you going to copy it from? and yes the 2nd file was a joke but you will just need to change the header and the secuirty routines to display an error instead
-
Directory Permissions Denied using this script
MadTechie replied to Demonic's topic in PHP Coding Help
erm.. 550 Could not change perms on icon_www.gif: Operation not permitted : /public_html/l337/GZ/templates/subSilver/images/lang_english/0777 icon_www.gif this looks wrong to me unless you have a file called "0777 icon_www.gif" -
Heres an idea have a php page that uses the zip encoding header, and have that connect to a database (security check think), if the secuity check is passed then use readfile("thefile.zip"); to build the read of the zip if not use readfile("not_thefile.zip"); (for fun to give them a junk file which contains only a readme.txt telling them where to stick it
-
I'm an O'Reilly fan.. but skipping chapters doesn't work.. plus the Pear chapter does state in addition to your comment again from the O'Reilly book about PEAR so i say again read the chapter again or any you missed
-
i would change echo "<td width=100><div align=left class=main_txt>$row[lastname]</td></div><td width=100><div align=left class=main_txt>$row[firstname]</td></div><td width=100><div align=left class=main_txt>$row[rep]</td><td width=100><div align=left class=main_txt>$row[hours]</td></div><td width=100><div align=left class=main_txt>$row[status]</td></div></div></tr></table></center>"; } to something like echo "<td width=100><div align=left class=main_txt>$row[lastname]</td></div>"; echo "<td width=100><div align=left class=main_txt>$row[firstname]</td></div>"; echo "<td width=100><div align=left class=main_txt>$row[rep]</td>"; echo "<td width=100><div align=left class=main_txt>$row[hours]</td></div>"; if($row[status] == "active") { echo "<td width=100><div align=left class=active>active</td>"; }else{ echo "<td width=100><div align=left class=inactive>inactive</td>"; } echo "</div></div></tr></table></center>"; }
-
are the zip files stored on a webserver or are they dynamically created zip files, if they are dynamically created then that maybe the problem (timeouts)
-
Tip #1 Break the project down in to small parts/projects Tip #2 Break those parts into smaller parts Tip #3 test each part with known data until you get expected results so now you have a drop down list create one which just displays a table with all data then modify it to find defined data, then merge them together
-
infact the @ doesn't "fix" it, it just surpresses the error message
-
because your setting it.. $searchtype = mysql_real_escape_string($_POST['searchtype']); use if(isset($_POST['searchtype']) > 0){
-
if you enter a page with "?something=other" ie index.php?something=other the php page can pull that infomation for example echo $_GET['something']; // will return "other"
-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <title>Sweet form</title> </head> <body> <?php echo "some sweet text ".$_GET['myText']; ?> <form method="get"> <input name="myText" type="text" value="sometext" /> </form> </body> </html>
-
<?php $line = $_GET['s1']; //Get the string from the URL $cuffx = strtolower($line[cuff]); // <-- your problem ?> change to $cuffx = strtolower($line);