Jump to content


  • Posts

  • Joined

  • Last visited


Profile Information

  • Gender
    Not Telling

widox's Achievements


Newbie (1/5)



  1. It would help if you posted your code.
  2. You could always hard code the IP for the subdomain in your hosts file. In /etc/hosts sub.domain.net sub Try that out. Other then that, you're going to have to edit your DNS/Firewall to allow that access. HTH
  3. Yes, that is where the Notice error is coming from. You're checking a variable $tmp_name but that variable doesn't exist. Do you have something on your form asking for a file name or something? If so then do something like if(!empty($_POST['file_name']) { $tmp_name = $_POST['file_name']; else $tmp_name = ''; Then you won't get that Notice message and your page will re-direct like you want it to.
  4. haha. I don't understand your line of though how fixing the undefined variable problem wouldn't allow it to be re-directed... The Notice Warning: Cannot modify header information - headers already sent by comes AFTER the Notice: Undefined variable: tmp_name in the same file. Because you can't issue a header(s) after there has been output. lander, declare the $tmp_name variable and you'll be set. Try it.
  5. You also need to learn how to use the text editor.. I think you've got a bit to many [ code ] bits in there. Anyway, just wrap the * in an element. <? if($missing && $_POST['City'] == '') print "<em>*</em>" ?></td> </tr> Then use CSS to target that element (em). Such as .style5 em { color: red; } HTH
  6. True, but the reason that it's not redirecting is because that Notice of an undefined variable.
  7. Well, what exactly does $desired_num represent and how does the user/code pick it? Best bet would be to use that as criteria in your SQL statement. Such as SELECT * FROM NamesTbl WHERE id = SOMEID or somesuch where clause. Then you'll only need to retrieve 1 record instead of ALL records. Then you can simply display the results of your query and be done.
  8. That's not really fixing the problem thesaleboat. You need to figure what $tmp_name is supposed to be. You are using it here if (file_exists($tmp_name)){ but I don't see it being set anywhere. Fix that and the notice will go away and it should then redirect.
  9. Looks to me like your FTP server path isn't correct. Are you on a shared host? The paths are usually something different then what you think. Try creating an empty PHP script and echo out $_SERVER['SCRIPT_FILENAME'] and see what it says. Oh, put it in the folder your trying to access and put that path in your FTP script and test again.
  10. Do some searching on API's, in particular REST (Representational State Transfer) http://en.wikipedia.org/wiki/Representational_State_Transfer. It's a simple architecture for communicating services. Also, check out oAuth for authentication. This could potentially be a pretty large project. On the other hand, you could just create a couple PHP scripts on your server(s) and call them with cURL and parse the response as needed. Depends on how far you wanna go. HTH
  11. You should read up on that http://us2.php.net/manual/en/features.file-upload.php Essentially after the file(s) have been uploaded, you can access the file info with the $_FILES global. $_FILES['userfile']['name'] is the name of the file So you can just add that name to the string of your email body and send it along.
  12. Check out the mail() function. http://us3.php.net/manual/en/function.mail.php
  13. Ok, that makes it easy to approach. while($row = mysql_fetch_array($result)){ if(strpos($row['link'], 'lakesideca.com') === false) { $linkTarget = '_blank'; } else { $linkTarget = 'container'; } echo "<font color= maroon><font size=2>"; echo $row['event']; echo "</font>"; echo "<font color= black><font size=2>"; echo $row['article']; echo "</font>"; echo "<a target=\"$linkTarget\" href='$row[link]'> Go there[/url]"; echo "</font>"; echo ""; echo ""; } The if statement simply checks if the string "lakesideca.com" (internal links) is in the link field, and if so sets $linkTarget to "container", otherwise it must be external so it get set to _blank. That should get you on your way. caution: quick off-the-cuff untested code
  14. OK. What is the format of your $row['link']? Are they absolute URL's or relative? If the former, you can simply check for your domain. For the latter, external URL's must begin with http:// so you could check if that exists. Then you just alter the link HTML accordingly.
  15. haha, well that's why your script won't run! They must have it setup differently for web scripts. You'd need to contact your hosting company. First try enabling that PHP5 option and see what happens!
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.