
BobcatM
Members-
Posts
92 -
Joined
-
Last visited
Never
Everything posted by BobcatM
-
Not real sure what's going on, might try posting some code? On a side note, I used a Hypertherm 1250 today haha..
-
As for the database, you should store them as BLOB if you are going to actually store the image in there. You wouldnt normally store the actual image in the database, rather store/fetch its name from the database and include that in a html <img src="images/<?=$image_name_here?>"> tag.. General speaking the files will be created 0644 but if that is not the case on your server you will need to chmod() them to at least this permission for them to be web viewable.
-
Post your code.
-
{"Requested By"} needs to be ['Requested By'] Make them all like that.
-
Post your whole code and lets have a look.
-
Can't upload anything larger than 10 KB? (Yes, Kilobytes)
BobcatM replied to Punk Rock Geek's topic in PHP Coding Help
change this value in php.ini upload_max_filesize = 30M Also depending on the method you use for the upload you might need to change the post_max_size option. post_max_size = 30M -
<?php $word = new COM("word.application") or die ("Could not initialise MS Word object."); $word->Documents->Open(realpath("Sample.doc")); // Extract content. $content = (string) $word->ActiveDocument->Content; echo $content; $word->ActiveDocument->Close(false); $word->Quit(); $word = null; unset($word); Read this: http://www.developertutorials.com/blog/php/extracting-text-from-word-documents-via-php-and-com-81/
-
If you can't remeber what makes you think we can?!
-
Could I ask where you have looked around at? http://www.google.com/search?hl=en&q=form+validation+php&aq=f&oq=&aqi=
-
Here is the one I used at one time. <?php exec('tail /usr/local/apache/logs/error_log', $output); ?> <Table border="1"> <tr> <th>Date</th> <th>Type</th> <th>Client</th> <th>Message</th> </tr> <? foreach($output as $line) { // sample line: [Wed Oct 01 15:07:23 2008] [error] [client 76.246.51.127] PHP 99. Debugger->handleError() /home/gsmcms/public_html/central/cake/libs/debugger.php:0 preg_match('~^\[(.*?)\]~', $line, $date); if(empty($date[1])) { continue; } preg_match('~\] \[([a-z]*?)\] \[~', $line, $type); preg_match('~\] \[client ([0-9\.]*)\]~', $line, $client); preg_match('~\] (.*)$~', $line, $message); ?> <tr> <td><?=$date[1]?></td> <td><?=$type[1]?></td> <td><?=$client[1]?></td> <td><?=$message[1]?></td> </tr> <? } ?> </table>
-
Does not look like you are executing your querty at the end, you are just storing the query in $sql. mysql_query($sql) or die ("Unable to connect!");
-
That is always a good practice.
-
How do i detect a capital letter in a sentence
BobcatM replied to receiver19's topic in PHP Coding Help
<? $str="GetToKnowYou"; preg_match_all('/[A-Z][^A-Z]*/',$str,$results); ?> Or an easier way. -
How do i detect a capital letter in a sentence
BobcatM replied to receiver19's topic in PHP Coding Help
<?php $string = $_GET['string']; $count = strlen($string); $i = 0; $ii = 0; while($i < $count) { $char = $string{$i}; if(ereg("[A-Z]", $char, $val)){ $ii++; $strings[$ii] .= $char; } else { $strings[$ii] .= $char; } $i++; } var_dump($strings); ?> -
Post your updated code, so I can see what you have done.
-
What code do you have so far?
-
You can't do a popup in php, you will have to use Javascript if you want a popup calender.
-
<?php $null = null; if($null == null){ echo "Yes, it is equivilent to null\n"; } if($null === null){ echo "Yes, it is null\n"; } if(isset($null)){ echo "Yes, it is set\n"; } if(empty($null)){ echo "Yes, it is empty\n"; } ?>
-
Post Code I do not understand you.
-
You are redirecting all statements to http://www.utilaecology.org/contact/response.php Try this and see if you can tell if it's going though the whole IF statement. <?php $name = $_REQUEST['name'] ; $email = $_REQUEST['email'] ; $date = $_REQUEST['date'] ; $dive_site = $_REQUEST['dive_site'] ; $depth = $_REQUEST['depth'] ; $additional_information = $_REQUEST['additional_information'] ; if (!isset($_REQUEST['email'])) { echo "No email entered"; } elseif (empty($email) || empty($dive_site)) { echo "Else If Statement"; } else { mail ( "[email protected]", "Report Lionfish Sighting Form", "Date: $date\n", "Dive Site Location: $dive_site\n", "Depth: $depth\n", "Additional Information: $additional_information\n", "From: $name <$email>" ) ; echo "Everything is good here"; } ?>
-
Well after trying it myself, did a little searching, I found this. http://cowburn.info/2008/01/12/php-vars-curly-braces/ Should answer your question.
-
Don't quote me, and I am sure I will get corrected, but I do not think ${0x0} is a valid variable. Must start with a letter or underscore.
-
<?php if($value = "") echo "Value is Null"; else echo "There is something in there"; ?>