- Upvotes Received
- 4
- Posts with Upvotes
- 4
- Upvoting Members
- 3
- Downvotes Received
- 0
- Posts with Downvotes
- 0
- Downvoting Members
- 0
35 Posted Topics
Re: If you have a textarea with the name of "content", and replace that with an instance of a CKEditor, then when the form is submitted, there will be a $_POST['content'] item. If you're instantiating the editor via PHP & not Javascript, then I'm sure there's a parameter somewhere to set … | |
Re: "functions"? Is this Javascript not working? If you meant "functionality" because parts of the page don't display correctly - welcome to web development. IE7/8/9, Firefox, Chrome, Opera all have different rendering engines (or versions thereof) so they don't all display the same code the same way. My approach is generally … | |
Re: A lot of providers have an email address for each customer that you can send emails to. Those emails get converted to text messages/SMS automatically & without charge to the sender. | |
Re: strtotime() was created for this exact purpose. [url]http://ca.php.net/manual/en/function.strtotime.php[/url] ![]() | |
Re: What is $VISITOR supposed to be? You're treating it like an object, but the code you posted doesn't show it being instantiated. | |
Re: Not sure you need to treat the url as a regex in your condition. This should work: [CODE]RewriteCond %{HTTP_HOST} www.example.com [NC][/CODE] Also, requests to the subdirectory itself will satisfy your condition, so you have a circular reference there. You need a new condition that causes the rule to only work … | |
Re: Actually, 1000 bytes = 1 KB. KB, MB, GB, TB are all metric units of with base 10. If you're using the base 2 equivalents, the units are KiB, MiB, GiB, TiB, etc. [url]http://en.wikipedia.org/wiki/Kibibyte[/url] | |
Re: I've never tried to prevent copy-and-paste-ing, but I wonder if putting a full screen div over top of everything might do the trick. With proper z-indexing, the div would be placed above the text. Unfortunately I'm thinking you'll have to have a background colour in order for the div to … | |
Re: [QUOTE=evstevemd;1400771]sudeep, id is autoincrement and I don't programatically know where new book or chapter begins at as far as ID is concerned. Thanks for replying[/QUOTE] Can you do 1 query to get the IDS (say, Genesis 1:1 = ID 1, Psalms 2:30 = ID 4562), then ask for anything between … | |
Re: How you integrate it depends on the editor. The most common ones are CKEditor and TinyMCE. You're painting yourself into a corner a bit by both wanting the user to provide rich text formatting, but also being concerned about html injection. About the only thing you can do is to … | |
Re: Allow the BLOB/TEXT fields to be NULL. | |
Re: Or even the datetime field type. Basically how you're storing dates is the worst possible way, because you can't do simple calculations on it. | |
Re: You don't want to decode the entirety of $_POST. $_POST is, at it says, an array. You want to decode $_POST['name']. Also, you'll probably want to do a check if magic quotes is on, and strip any slashes if it is. Finally, I see your JSON has a trailing comma … | |
Re: I'm relatively new to these boards - but most PHP forums don't simply do your work for you. You need to provide some code & evidence of what you've tried yourself rather than get someone on the Internet to do your work for you. | |
Re: Ultimately this is a moot point, because the file extension really has no bearing on what the file actually is - especially if this is a *nix server. If you want to prevent bad files from being uploaded, you'll need to check their MIME types. You can do that with … | |
Re: Somewhere you do need to create a list of which actions can be executed by which users. If you've got a large number of users, the best way to do this is with access control groups. This simply means you put users into certain groups (for example, "editors", "administrators", etc), … | |
Re: You posted the wrong code. The error says output started in login.php, but you posted code for, I'm guessing, authentication.php. | |
Re: preg_match_all() with this expression should work [code]/Start(.*?)End/[/code] | |
Re: Does your host support IMAP? If so, then you can use any number of web-based email programs & just point them at your server | |
Re: - Attach a click listener to the button. - When the button is clicked, generate 3 random numbers between 0 and 255. - Set the backgroundColor property to use the rgb() colour system with those 3 numbers representing Red, Green, Blue: [code=javascript]element.style.backgroundColor = "rgb("+randomRed+","+randomGreen+","+randomBlue+")";[/code] | |
Re: If your list of words-to-not-capitalize is relatively short, you could do this: [code=php] $string = "vegetable and goat's cheese terrine with pineapple pickle"; $uppercase = ucwords($string); $fixed = str_replace(array(' And ',' Of ',' The ',' A '),array(' and ',' of ',' the ',' a '),$uppercase);[/code] | |
Re: You need to configure DNS to have a wildcard DNS entry for all subdomains. This question was asked on [URL="http://stackoverflow.com/questions/183928/how-to-let-php-to-create-subdomain-automatically-for-each-user"]Stackoverflow[/URL] To be honest, simply doing [url]www.domainname.com/username/[/url] would be much simpler. | |
Re: Line 16 of your posted code. You're referencing $_GET['prod_name']. However, it appears $_GET doesn't have an element with the key 'prod_name'. | |
Re: The solution here should be two-fold: 1) When a user clicks the submit button, run some javascript to check that all your required elements have a value. If not, output a message to the user. This is mostly done as a convenience to the user - so they don't have … | |
Re: connection.php is where the error is being generated? I'm guessing you got that connection.php code from somewhere else, but failed to update it with your actual MySQL connection information. | |
Re: I think you might need to do 2 loops. One to do the count, the second to display. The first loop would go through & make a new array. The keys of this array would be the $product (I'm assuming it's a string), and the values would be the count. … | |
![]() | |
Re: Put the query in a string, and output that string. Your query is broken somehow. Remember to never put raw $_POST data in your query - run it through mysql_real_escape_string() first to avoid injection. Also, please wrap your code in tags. | |
Re: If you absolutely must run the query when the user closes the browser, you can trigger some Javascript on the close() event for the window. That Javascript can make an AJAX call to a PHP page that does the logout. However, my question is whether you really need to logout … | |
Re: After line 16, if the result of strlen() on any of those three variables is empty, display the page again with an error saying what was missing - or whatever you want. | |
Re: You can't/shouldn't send 3 content-type headers. That doesn't make sense because the file only has one content type. That might be messing things up. Only send the octet-stream header. Rather than doing the fopen()...fclose(), just use your readfile() code - much simpler. The one thing to check though, is whether … | |
Re: You can store the link like that & use it the entire time your script is running. You're correct though - unless you're using persistent connections, the database connection will be terminated. What I don't understand is why PHP thinks $this->link is NULL. It should either be a valid resource … | |
Re: 2 things influence how fast it will appear to upload. 1) The user's connection speed. If they're connected through dial-up, there's not much you can do to make it faster. This is the lion's share of the time 2) Your processing time. Quite small relative to the time it takes … | |
Re: Try echoing your query right before you execute it - to see if it's what you expect. | |
Re: Yes, you can have Javascript in a PHP file - in that you can call a PHP file & have it act as Javascript...but I don't think that's what you want. I believe what you're asking is if you can make Javascript & PHP work together & ensure sessions are … |
The End.