Jump to content

jdock1

Members
  • Posts

    210
  • Joined

  • Last visited

    Never

Everything posted by jdock1

  1. Im still not sure what to do. I really want to get this code to work. Can anybody else help me out?
  2. the script starts out: "If the referrer contains google and search", mail this message. Running it from your own server will not work unless you modify your UA to pretend to be a google page. Thanks, do you know how to modify the user agent?
  3. Sorry for the spam today, ive been on the computer all day trying things out due to the weather, so I have nothing better to do anyway, I saw this code on this site , its a script that emails you when somebody is referred to your site via google heres the code <?php // Script to email you when Google refers traffic to your site. $name=""; // add your name here $email_address=""; // add your email address here $keywords=""; $referrer=$_SERVER['HTTP_REFERER']; if( (stristr($referrer, "google")) && (stristr($referrer, "search")) ) { parse_str($referrer, $output); $keywords=$output['q']; $email_message="Hi $name, A visitor just arrived to your site after searching for '$keywords'. ($referrer)"; mail ("$email_address","Google referred a visitor","$email_message"); } ?> I filled out all the necessary variables, but cant get it to work. Is there something missing? I tried making it a seperate file, and used function.include() to include it, that didnt work. I tried html object tags, that didnt work, then I just put that code in the page. Nothing working. What could it be? Thank you all for your support, thanks to you all, I am making php applications that I thought I never could!
  4. Im trying to set up a swear word filter, one where when the user enters the swear word into the text box is echos an error This is what I have: if ($query == "shit || fuck || titties || penis || vagina") { echo "No swearing"; } I also tried setting up this array: $swearwords = array("swearword", "badword", "anotherswearword", "anotherbadword"); And used this if statement: if ($query == "$swearwords") { echo "No swearing"; } Im somewhat a beginner in PHP and thought this would work but Im probably just an idiot. What am I doing wrong?
  5. I see some sites using PHP as kinda like directories, for example a site is like site.com/index.php/page:2 or site.com/contact_form.php/ and when the submit button is pressed site.com/contact_form.php/action/send What are they doing here? It makes no sense to me
  6. I want to stealth PHP, instead of using extensions I would be using something like mysite.com/file rather than mysite.com/file.php I do this by a htaccess file with this code: RewriteEngine on RewriteBase / RewriteRule file file\.php [T=application/x-httpd-php] It seems that $_GET doesnt work, I tried using $_REQUEST, which actually works but not all the time. Is there anyway I could use $_GET? Or anything else? Thanks!
  7. Im looking into coding a simple incentive script, but i cant figure out how to make a postback file? Affiliate companies like copeac will ping to your server through a file specified to notify the server that a lead has been generated, but I dont know how to code this. They postback by subids, etc. Anybody know how I could go about doing this?
  8. I added the access me toolbar n got pretty much the same result with ebay "http://ebay.com/ :: Cookie + Http Method Attack Details: * Input Parameter: nonsession * HTTP Method: HEAD The attacked page is dangerously similar to the original page. It is 96.225% similar. Did not access protected resource. Server response code: 301 Moved Permanently. " This toolbar seems to assume bad html or invalid xhtml as an attack of some sort this shits bogus
  9. Whats the definition of "bad stuff" , im still new to php n would like to know all this security bullshit damn, php is complicated
  10. uhh thats it thanks. I knew that, but I didnt know to use switch
  11. Im still a noob in PHP & got a rather stupid question. Many sites running php use pretty much one php file for everything. For example, a site uses index.php for everything. There are other pages defined as index.php?id=1 & index.php?id=2 etc. Ive been trying code out and cant really do it all that well. Could somebody explain this for me? Thanks
  12. Everybody is looking for a php mail script, its so easy to code , but webmasters that dont know shit about php will look around for one. This way, the idiot who doesnt know php doesnt have to actually go into the php code and put their email address in their manually
  13. I made a php mail script, but I want it to be made so the user can enter his email address in the text box, then when he clicks submit it generates the php file for him, the email address he entered is hardcoded in the file by using a $_GET variable.. I already tried that with this code on top header("Cache-Control: no-cache"); header("Expires: -1"); header("Content-disposition: attachment; filename=\"send.php\""); header("Content-type: application/octet-stream"); ...but it downloads the html, no php code. Is this possible?
  14. I thought it was a neat idea, & thanks for all the help by the phpfreaks members, I was able to code this simple application. As you all may know, you can pretty much use any extension for PHP instead of the old .php or .phtml, you can use pretty much anything, such as .lol , .lookatthisextension im using, etc. With this very simple script, you enter what extensions you want to use, and it generates a file that you upload to the directory you want to use those extensions with. This isnt something im looking into making a site for, just a little hobby thing and for personal use. Try it out; http://phpdomain.co.cc/x/index.php Im using a testing .co.cc domain with free hosting for all my php projects
  15. Thanks for the help, actually the problem was that I forgot to edit the example variable to my variable name
  16. Hmm.. im getting header errors Warning: Cannot modify header information - headers already sent by (output started at /...:2) in /... on line 3 Warning: Cannot modify header information - headers already sent by (output started at /...:2) in /... line 4 Warning: Cannot modify header information - headers already sent by (output started at /...:2) in /... on line 5 Warning: Cannot modify header information - headers already sent by (output started at /...:2) in /... on line 6 you submitted: Any ideas?
  17. make a dynamic php page downloadable? Meaning, say the browser enters some text into a text field, which that text is a variable, and displays on the next page. When they click the submit button, the variable is displayed on that page. Is it possible to make it kind of like a popup window as if you were downloading something? This may sound pretty stupid. But im doing this kind of as a .htaccess generator, but I cant figure out how to have the user download the page. Thanks in advance!
  18. Im trying to make an application where a user can write to a line from a file template... how could I do this? To be more specific, I want to make an .htaccess generator, but there is only one line the user enters to generate the new file There is one text field in the application, the string the user enters in that line will write to the file and generate the file for them where they can download it I was looking into using fopen(),fwrite() functions etc, but this is a bit more complex and I have no idea how to do this..
  19. Could you please be more specific? I know that but I need to know the line to put in the .htaccess Like so for the extensions I added AddType application/x-httpd-php .lol .tits .smokecrack What would I put in there?
  20. I found out how to make PHP parse through any extension (I tried it with .asshole , .shit, etc. and it works) But is there anyway to make it with no extension, just the dynamic "?" rather than ".whatever?" So if I named a file like test.php , I want it instead of domain.com/test.php, I want it like domain.com/test , so when PHP parses a get variable it would be like "domain.com/test?name=Ryan" Is there anyway to do this? Thanks!!
  21. Thanks bro, but I still cant figure it out. Im trying to make a link on the php page that has the anchor "view php source" where they can, of course, click it and get the php source. Thanks for the help bro
  22. Yall are probably laughin at me. I am such a noob at php but learning fast. Im trying to discover the show_source() function, but dont know how to implement it. I tried just putting show_source() in the php code, but that didnt do anything. Then, I tried echo "show_source()"; Now, im trying stuff like <a href="<?php show_source()?>" in the HTML How the hell do I use this!?
  23. I coded a simple three part register/login script, the register page, the login page, and the member page. I coded this with a PHP pocket reference book. So now, I face the problem of making php pages login protected. I added this code to the pages that I want to be login protected: <?php session_start(); if ( @$_SESSION['cookie'] != "yes" ) { header("Location: login.php"); exit (); } ?> The redirect works to login.php, but when I login and go to that page (for example, test.php), it redirects me to the member page. What am I doing wrong?? Thanks in advance!
×
×
  • 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.