
megetron
Members-
Posts
53 -
Joined
-
Last visited
Never
Everything posted by megetron
-
I found this : Mail_Queue - Pear - PHP exactly like I needed. Thanks,
-
I am using shared host, is it possible to use this classes?
-
Hello, I have some troubles to send mass email. I am using mail() function and the script is timed out. also there is a restriction in which you allowed to send 20 mails per minute. so I use sleep(5) to delay 5 seconds between every mail, but the script is exceeded timeout. Adding this: set_time_limit(0); will still not work. maybe can I set a background thread? if so please tell me how to. Also, if there is a built in script that can help me with that, I would like to hear about it. Thanks =]
-
hello, I am trying to read logs of PHPIDS logs: "27.116.15.205",2012-04-27T15:48:40-04:00,142,"xss csrf id rfe lfi sqli","REQUEST.S1%3D%2520%2520%2520%2520%2520%2520%2520%2520%2520%2520%2520%2520%2520%2520%2520%253C%2521--%2520START%2520sd%2520-%2520%25D7%25AA%25D7%2595%25D7%259B%25D7%25A0%25D7%2599%25D7%25AA%2520%25D7%25A9%25D7%2595%25D7%25AA%25D7%25A4%25D7%2599%25D7%259D%2520CODE%2520--%253E%250D%250A%253Cscript%2520language%253D%255C%2527javascript%255C%2527%2520%2520type%253D%255C%2527text%252Fjavascript%255C%2527%253E%250D%250Avar%2520r%253Ddocument.referrer%253B%250D%250A%2520var%2520counter%2520%253D%2520new%2520Object%2528%2529%253B%250D%250Acounter.src%2520%253D%2520%255C%2527http%253A%252F%252Fdf.co.il%252Ft.php%253Faid%253D99%2526linkid%253DB74%2526r%253D%255C%2527%252Br%253B%250D%250A%253C%252Fscript%253E%253Cscript%2520src%253Dhttp%253A%252F%252Faf.co.il%252Ft.php%253Faid%253D99%2526linkid%253DB74%253E%250D%250A%253C%252Fscript%253E%250D%250A%253C%2521--%2520END%2520dsf%2520-%2520%25D7%25AA%25D7%2595%25D7%259B%25D7%25A0%25D7%2599%25D7%25AA%2520%25D7%25A9%25D7%2595%25D7%25AA%25D7%25A4%25D7%2599%25D7%259D%2520CODE%2520--%253E%250D%250A%250D%250A%2520%2520%2520%2520%2520%2520%2520%2520%2520%2520%2520%2520%2520%2520%2520%2520+POST.S1%3D%2520%2520%2520%2520%2520%2520%2520%2520%2520%2520%2520%2520%2520%2520%2520%253C%2521--%2520START%2520af%2520-%2520%25D7%25AA%25D7%2595%25D7%259B%25D7%25A0%25D7%2599%25D7%25AA%2520%25D7%25A9%25D7%2595%25D7%25AA%25D7%25A4%25D7%2599%25D7%259D%2520CODE%2520--%253E%250D%250A%253Cscript%2520language%253D%255C%2527javascript%255C%2527%2520%2520type%253D%255C%2527text%252Fjavascript%255C%2527%253E%250D%250Avar%2520r%253Ddocument.referrer%253B%250D%250A%2520var%2520counter%2520%253D%2520new%2520Object%2528%2529%253B%250D%250Acounter.src%2520%253D%2520%255C%2527http%253A%252F%252Fdf.co.il%252Ft.php%253Faid%253D99%2526linkid%253DB74%2526r%253D%255C%2527%252Br%253B%250D%250A%253C%252Fscript%253E%253Cscript%2520src%253Dhttp%253A%252F%252Fdf.co.il%252Ft.php%253Faid%253D99%2526linkid%253DB74%253E%250D%250A%253C%252Fscript%253E%250D%250A%253C%2521--%2520END%2520df%2520-%2520%25D7%25AA%25D7%2595%25D7%259B%25D7%25A0%25D7%2599%25D7%25AA%2520%25D7%25A9%25D7%2595%25D7%25AA%25D7%25A4%25D7%2599%25D7%259D%2520CODE%2520--%253E%250D%250A%250D%250A%2520%2520%2520%2520%2520%2520%2520%2520%2520%2520%2520%2520%2520%2520%2520%2520","%2Fa%2Findex.php%3FAct%3Dgetbanner","232.1.201.16" "293.21.209.2",2012-04-27T16:25:08-04:00,22,"xss csrf id rfe lfi","REQUEST.__utmz%3D69327680.1335558235.1.1.utmcsr%253Da.com%257Cutmccn%253D%2528referral%2529%257Cutmcmd%253Dreferral%257Cutmcct%253D%252FCategory.aspx+COOKIE.__utmz%3D69327680.1335558235.1.1.utmcsr%253Da.com%257Cutmccn%253D%2528referral%2529%257Cutmcmd%253Dreferral%257Cutmcct%253D%252FCategory.aspx","%2Fa%2Frcode.php%3Fid%3D135%26af1d%3D55%26width%3D180%26height%3D150","212.1.218.1" how can I do this?
-
hi all, I have an issue that happens for my website users. but it happens only for few and I cannot reproduce the problem. There is the following code that opens a new box with details: <a href="#displayBox" onclick="javascript:ShowCommissionDetails('1','2');">Commision</a> <script> function ShowCommissionDetails(pId, aId) { if(pId){ document.getElementById('div_faded').style.display='block'; document.getElementById('div_ViewCommission').style.display='block'; document.getElementById('div_faded').className="showProgramCommissionFadeDiv"; var url = "CommissionDetails.php?pId="+pId+'&aid='+aId; ajaxpage(url,'div_ViewCommission'); } } function CloseCommissionDetails() { document.getElementById('div_faded').style.display='none'; document.getElementById('div_ViewCommission').style.display='none'; } </script> some of my users says that it doesnt work...but I just cannot reproduce, can you have a guess what might be wrong with that code? Thanks,
-
hi, I would like to convert a php string like "that's all folks!" to javascript string "that\'s all folks", so I can write something like: diocument.write('<?$myString?>'); so of course i can replace ' with \' with replace function but is there a php function that do this for the specific charachter and for other special charchters too? what is the best way do this? Thanks guys,
-
How do I wait for javascript file to be fully loaded ?
megetron replied to megetron's topic in Javascript Help
I would like to provide a script for webmasters. the webmaster calls my php page (with javascript call) and gets html advertisment... -
How do I wait for javascript file to be fully loaded ?
megetron replied to megetron's topic in Javascript Help
here is how I call the script above: <body> <script language="javascript" type="text/javascript" src="http://domain.com/r.php?id=154"></script> </body> but it doesn't work. when I change the code to that: <body> <script type='text/javascript' src='http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js'></script> <script language="javascript" type="text/javascript" src="http://domain.com/r.php?id=154"></script> </body> the script works fine.... -
Hi, I need to wait for a javascript file to be loaded by the client browser before executing rest of the script. (I dont have access to the HEAD tag, because the script I develop is being called from other users page). Here is what I am trying to do without success: echo "document.write(\"<script type='text/javascript' src='http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js'></script>" ."<link rel='stylesheet' href='http://domain.com/css/style.css' type='text/css' media='screen'/>\");"; echo "document.write(\"<script>var newScript; newScript = document.createElement('script'); " ."newScript.type = 'text/javascript'; " ."newScript.src = 'http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js'; " ."document.getElementsByTagName('head')[0].appendChild(newScript);</script> \");"; sleep(5); $list = "<link rel='stylesheet' href='http://domain.com/style.css' type='text/css' media='screen'/><p id='last'></p><div id='slidebox'>" ."<a class='close'></a>" ."<p>TITLE</p>" ."<h2>DESC</h2>" ."</div>" ."<script type='text/javascript'>" ."$(function() {" ."$(window).scroll(function(){" ."var distanceTop = $('#last').offset().top - $(window).height();" ."if ($(window).scrollTop() > distanceTop)" ."$('#slidebox').animate({'right':'0px'},300);" ."else " ."$('#slidebox').stop(true).animate({'right':'-430px'},100); " ."});" ."$('#slidebox .close').bind('click',function(){" ."$(this).parent().remove();" ."});" ."});</script>"; echo "document.write(\"$list\");"; exit;
-
please help me strength security on my site.
megetron replied to megetron's topic in PHP Coding Help
Thats exactly how I am doing this. Also, I have try to include this code inside the php page itself and still it won't work. please help, -
Hi, There is a page in my site that echo varible $msg. so when i goto http://mydomain.com/page.php?msg=<script>alert("HELLO")</script> the page will prompt the alert HELLO....(echo $msg;) what i wish to do is to create 1 file that will be included in all of my pages to prevent such behaviour. so I created a new file likw this to prevent: <? reset ($_GET); foreach ($_GET as $key => $value)//to stripslash all get variables { $value=strip_tags($value); $value=stripslashes(trim($value)); $$key=$value; //echo "$key=>$value <br/>"; //echo ("<script>alert('sad')</script>"); } reset ($_POST); foreach ($_POST as $key => $value)//to stripslash all posted variables { $value=stripslashes(trim($value)); $value=strip_tags(trim($value)); $$key=$value; //echo "$key=>$value <br/>"; } reset ($_GET); reset ($_POST); ?> but for some reason it doesn't work but when I dont include anything and change the page code for this: echo strip_tags($msg); the alert will not be displayed.... Can you please help me build a secured page to include in my pages, so there will not be hacking in my GET/POST/COOKIES/SESSION objects? even if there is something that you are using or some class/function ready to use that being tested will be great solution for me to strength security. Thank you guys.
-
hi, I need to save array of elements form INPUT html element to a database, and on other page I need to display it again, so I need to SET the INPUT element again. here is th input array: <input type='hidden' name='elements[]' value='$categories' />" how do I do that? Thank you.
-
Hello, I have php application, it is hosted on a shared server. How can I view the errors in my application with the details of the error for my website users? Thanks,
-
Hi, I am looking for componnent of a rich media, so I can show my ads on my website in a very interactive way. I found this: http://www.checkm8.com/products/advantage-richmedia/gallery but this is very expensive one. is there any other solutions you know? Thanks,
-
Hello, Is there any control/component to bypass the popup blockers? Please advice. Thanks,
-
Hello php freaks, I have a strange problem that happens to one of my clients. when using firefox he gets this error "a plugin is needed to display this content" for flash files display. he can see other flash files from other sites. even from my website (on other pages). but not from a specific page called "code.php" . code.php : $topm = $track_site_url."/m/images/flash/".$width."_".$height.".swf"; $trackurl = "$track_site_url/trackingcode.php?aid=$affilid&linkid=F$curid&Act=Rotator"; $trackurl_ForFlash = str_replace("&","%26",$trackurl); $imagelist = "<object classid=clsid:D27CDB6E-AE6D-11cf-96B8-444553540000 codebase=http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0 width=$width height=$height><param name=movie value=$cururl?clickTAG=$trackurl_ForFlash /><param name=quality value=high /><EMBED src=$cururl?clickTAG=$trackurl_ForFlash quality=4 width=$width height=$height pluginspage=http://www.macromedia.com/go/getflashplayer/></object>"; } echo "document.write('$imagelist');"; The client translate in his web page this code: <script language="javascript" type="text/javascript" src="http://domain.com/affiliates/code.php?id=11324240&affilid=1000107&width=160&height=600"></script> can you take a wild guess what this can be? Thanks,
-
Hi, I am trying tocreate a simple form that do submit (form for mobiles). But the code does not do a submit (debug it and the success function is not executed on submit). here is the code: <form id="ContactForm"> <p class="mandatory"> </p> <div data-role="fieldcontain" class="text-field"> <label for="LAST_NAME">שם מלא:</label> <input type="text" name="LAST_NAME" value="" placeholder="" class="required" id="LAST_NAME" /> </div> <div data-role="fieldcontain" class="text-field"> <label for="mobilephone">טלפון:</label> <input type="number" name="PHONE_MOBILE" value="" placeholder="" id="PHONE_MOBILE" /class="required" > </div> <div class="send"> <a href="javascript:;" data-role="button" data-theme="a" data-iconpos="right" id="send">הרשמה!</a> <input type="submit" name="submit" value="Submit" id="send1"/> </div> <input type="hidden" name="LEAD_SOURCE" value="MOBILE"> <input type="hidden" name="ASSIGNED_USER_ID" value="fe1032ed-fbe7-44b7-b724-8b9dc7e6e01b"> <input type="hidden" name="MODIFIED_USER_ID" value=""> </form> and the function: $('.returnTopAction').live('click', function() { $('html, body').animate({scrollTop: '0'}, 700); }); $('#gallery-page').live('pageshow', function () { $myPhotoSwipe = $(".gallery a").photoSwipe({ enableMouseWheel: false , enableKeyboard: false });}); $('#send').live("click", function() { var url = 'http://crm.karusela.net/Leads/WebToLeadCapture.aspx'; var error = 0; var $contactpage = $(this).closest('.ui-page'); var $contactform = $(this).closest('.contact-form'); $('.required', $contactform).each(function(i) { if($(this).val() === '') { error++; } }) // each //alert($contactpage); if(error > 0) { alert('ERR'); } else { //submit the form $.ajax({type:'GET', url: url, data:$('#ContactForm').serialize(), success : function(data) { alert("THIS FUNC DOES NOT EXECUTED"); if(data == 'success') { // show thank you $contactpage.find('.contact-thankyou').show(); $contactpage.find('.contact-form').hide(); } else { alert('ERR.'); } } }); } return false; });
-
Hi, on my cpanel I can see some errors: [Mon Mar 12 08:41:05 2012] [error] [client 46.120.43.163] File does not exist: /home/affilinn/public_html/504.shtml, referer: http://www.mysite.com/admin/ [Mon Mar 12 08:33:25 2012] [error] [client 46.120.43.163] File does not exist: /home/affilinn/public_html/404.shtml [Mon Mar 12 08:33:25 2012] [error] [client 46.120.43.163] File does not exist: /home/affilinn/public_html/404.shtml [Mon Mar 12 08:30:12 2012] [error] [client 46.120.43.163] File does not exist: /home/affilinn/public_html/404.shtml [Mon Mar 12 08:30:12 2012] [error] [client 46.120.43.163] File does not exist: /home/affilinn/public_html/favicon.ico [Mon Mar 12 08:30:12 2012] [error] [client 46.120.43.163] File does not exist: /home/affilinn/public_html/504.shtml, referer: http://www.mysite.com/admin/ [Mon Mar 12 08:29:55 2012] [error] [client 46.120.43.163] File does not exist: /home/affilinn/public_html/404.shtml [Mon Mar 12 08:29:55 2012] [error] [client 46.120.43.163] File does not exist: /home/affilinn/public_html/favicon.ico what is that?
-
no one?
-
Gateway Time-out and error 504 is displayed sometimes...
megetron replied to megetron's topic in PHP Coding Help
no proxy internet and never had 504 errors with other sites. when the 504 will happen again, I will paste it. today I had another error that happens sometimes: Internal Server Error The server encountered an internal error or misconfiguration and was unable to complete your request. Please contact the server administrator, [email protected] and inform them of the time the error occurred, and anything you might have done that may have caused the error. More information about this error may be available in the server error log. Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request. I just don't know where are this bizarre errors are come from. and the hosting support is avoid from solving this issue. If i can give them a direct instructions it might help. can you please advice? Thank you -
Hello, I am trying to export data from database. the exported data is creted with wrong encoding. I am using this code: header("Pragma: public"); header('Expires: '.gmdate('D, d M Y H:i:s').' GMT'); header("Cache-Control: must-revalidate, post-check=0, pre-check=0"); header("Cache-Control: private",false); header("Content-Type: application/force-download;charset=utf-8; encoding=UTF-8"); header('Content-Disposition: attachment; filename="'.$newFile.'"'); header("Content-Transfer-Encoding: binary"); header('Content-Length: '.@filesize($path)); Please help with the encoding. Thanks.
-
Gateway Time-out and error 504 is displayed sometimes...
megetron replied to megetron's topic in PHP Coding Help
I already did. they keep saying that everything si fine and they can view the website. what should I ask them to do or check for me? -
Hi, I have a form with a submit button (Delete button). after I click the button I do few changes in database. Problem is that in this form, after the submit made, it still shows me old data that deleted.... So, I guess I need somehow to make a page refresh through a GET method. How do I do this? Thank u!
-
Hi, when I browse my php website I recieve sometimes error 504. when it happens I try to refresh and get this error: Gateway Time-out The gateway did not receive a timely response from the upstream server or application. Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request. This website is in a shared hosting. Where can I find logs that will help me correct the issue? Thank you.