PHP - Moved: Bar At Bottom Of The Browser Window
This topic has been moved to CSS Help.
http://www.phpfreaks.com/forums/index.php?topic=319246.0 Similar TutorialsI'm working on customizing an open-source PHP CRM system (SugarCRM) and need some straightforward PHP help. I'm working thru an old example of writing changes to a log file and I'd like to take it one step further and open a new browser window once the save/write is done. Using the code below, could someone please direct me how to open the new window?. I basically want to pop open a new browser window from within the function below. I tried fopen, but it times out when going to a test URL such as http://www.cnn.com function UserToLog($strText){ $File = 'C:\wamp\www\log.txt'; $Handle = fopen($File, 'a'); $Data = $strText . "\n"; if($Handle){ fwrite($Handle, $Data); fclose($Handle); } //WANT TO OPEN NEW BROWSER WINDOW HERE...or wherever is correct. } All assistance is greatly appreciated. Thanks! This topic has been moved to HTML Help. http://www.phpfreaks.com/forums/index.php?topic=319527.0 This topic has been moved to HTML Help. http://www.phpfreaks.com/forums/index.php?topic=314530.0 This topic has been moved to HTML Help. http://www.phpfreaks.com/forums/index.php?topic=348773.0 This topic has been moved to JavaScript Help. http://www.phpfreaks.com/forums/index.php?topic=329157.0 This topic has been moved to JavaScript Help. http://www.phpfreaks.com/forums/index.php?topic=306168.0 This topic has been moved to JavaScript Help. http://www.phpfreaks.com/forums/index.php?topic=355464.0 This topic has been moved to JavaScript Help. http://www.phpfreaks.com/forums/index.php?topic=352282.0 This topic has been moved to HTML Help. http://www.phpfreaks.com/forums/index.php?topic=316203.0 This topic has been moved to PHP Applications. http://www.phpfreaks.com/forums/index.php?topic=333559.0 This topic has been moved to JavaScript Help. http://www.phpfreaks.com/forums/index.php?topic=347166.0 This topic has been moved to JavaScript Help. http://www.phpfreaks.com/forums/index.php?topic=317921.0 This topic has been moved to JavaScript Help. http://www.phpfreaks.com/forums/index.php?topic=317523.0 Scenario :
I would like to open the main program window and at the same time, if a condition is met, open a second - popup window to alert the user of previous information stored in the database.
This is an easy exercise if I use a hyperlink to open th second (popup) window but this is not the process required .
Can someone point me in the right direction ?
Cheers and thanks
I'm wondering what makes a pop-up login window run differently than inside a webpage. I can't seem to get my login system to bring the user back to the page (brings them to a page can't be found) when clicking a form submit button when it is included in the webpage. But if your in the popup page that I'm trying to include, it works no problem so I was wondering if it changes anything. Or if there is some sort of work around (such as embedding a popup window into the webpage). Thanks a lot! I'd like to use an application that's not browser based, on Internet Explorer. I've read somewhere that this is possible with a PHP script, but which one? If you can get me on the right track, I'd really appreciate it. Cheers. I have been staring at this code for hours trying to figure out what is wrong, I guarantee that someone is going to look at it and make me feel like a tool. The first query is not going through the list, the second is. It worked till I started updating to PDO. I have tested the SQL, that works, probably a flipping comma or a quotation mark screwing with my brain. Please look and spot the obvious balls up and point it out to me. as in I get a result that looks like this
Heading
I am expecting
Heading Why is this failing? Please show a doddering old fool what I am doing wrong... $query = $pdo->prepare("SELECT * FROM faq_cats WHERE faqc_site = :site ORDER BY faqc_id ASC LIMIT 0,4"); $query->bindParam(":site", $site); $query->execute(); while($row = $query->fetch(PDO::FETCH_ASSOC)) { $fid = $row["faqc_id"]; $faqc = $row["faqc_name"]; echo "<h2> ".$faqc." </h2>"; $query = $pdo->prepare("SELECT * FROM faqs WHERE faq_cat = :fid ORDER BY faq_id ASC"); $query->bindParam(":fid", $fid); $query->execute(); while($row1 = $query->fetch(PDO::FETCH_ASSOC)) { $faid=$row1["faq_id"]; $faqn=$row1["faq_question"]; echo "<a href=\"#".$faid."\">".$faqn."</a><br />"; } }
I have a problem with one div, I want to fix it at the bottom of the page and when I zoom the page I can see the div without scroll.
Is there a code I can put with each of these errors so that, on error, the page reloads back to the bottom of the page? When you enter the wrong info, the page already reloads but it reloads to the top of the page. People who didnt correctly information into the webpage may not see that they're receiving an error if it doesnt scroll back down. I attempted to put the error at the to of the page but I couldnt find a good spot. I thought about doing an error message box but I'm not sure thats the best method Anyway heres the code, thanks a lot. <?php if ($_POST['send']) { $errors = array(); if ($_POST['captcha'] != $_SESSION['captchacode']) { $errors[] = "You didn't enter the correct letters!"; <-------------ID LIKE TO PUT A CODE HERE AND } if (empty($_POST['email'])) { $errors[] = "Please enter an e-mail address"; <-----------------HERE TO MAKE THE PAGE GO TO THE BOTTOM WHEN IT REFRESHED (IT REFRESHES UPON EVERY IMPROPERLY FILLED OUT FORM } else if (!eregi("^[_a-z0-9-]+(\.[_a-z0-9-]+)*@[a-z0-9-]+(\.[a-z0-9-]+)*(\.[a-z]{2,3})$", $_POST['email'])) { $errors[] = 'Please enter a VALID e-mail address'; } if (!count($errors)) { // IMPORTANT: If you don't call this the // user will keep getting the SAME code! captchaDone(); not for certain this is a PHP issue, but on every page of my site, at the bottom, this error displays. Doesn't affect any of the code execution as far as I can tell, but it's annoying. Anyone else seen this? Code: [Select] Error in my_thread_global_end(): 1 threads didn't exit |