- Strength to Increase Rep
- +11
- Strength to Decrease Rep
- -2
- Upvotes Received
- 96
- Posts with Upvotes
- 84
- Upvoting Members
- 70
- Downvotes Received
- 5
- Posts with Downvotes
- 5
- Downvoting Members
- 5
344 Posted Topics
Re: Just to add onto GliderPilot's post, it's important that you make sure the string is uniform in how it separates e-mail addresses. In your code `person-1@here.com` and `person_2@there.net` are separated by a comma followed by a space, while `person_2@there.net` and `person.3@wayoverthere.com` are separated by a semicolon and a space. It … | |
Re: You can start with making sure you have a valid XML sitemap and submitting it to Google Webmaster Tools and Bing Webmaster Tools. | |
Hello, I'm hoping for some help with a regex that has me stumped. My skill with regex is rather rudimentary. To start, here are a couple of example URLs, and whether I want to match them or not: collection/col1 // MATCH collection/col2 // FAIL collection/col1/products/pro1 // FAIL My criteria: * … | |
Re: 1. As far as I recall, IF statements don't have their own scope in PHP. What is the URL you are visiting? If you are getting this error, chances are `$_GET["img_id"])` isn't set. 2. You're referencing `$img_id` on line 18, but you never initialized this variable 3. You're including the … | |
Hello, I'm just starting off with Ruby, but I have a task that landed on my desk that I need a quick answer for, and haven't been able to find a solution online. I appreciate any help I can get. I need to know if a value in one array … | |
Re: You'll need to use an exchange rate API, then parse/decode the results. Google and Yahoo each have APIs (a quick search should turn up more info), and another resource I found is https://openexchangerates.org/ EDIT: Just saw diafol's response. Sorry, had this tab open for a while before I got to … | |
Re: [QUOTE=Tickon;1242972]Ok, I'll give it a try, I'm not familiar with php yet, anyway to get around it?[/QUOTE] There is a difference between static sites and dynamic sites. Static sites stay the same until the author manually changes the code. A dynamic site changes based on certain events. Adding a comment … | |
Re: You don't close your statement that starts on line 64. Look at lines 65 and 66: 65. type='s 66. while ($row = mysql_fetch_array($result)) { I'm not sure where you're going on line 65 (I think a submit button), but you need to close it up with something like [icode]type='submit' />";[/icode]. … | |
Re: Are you sure you mean Photoshop and not Dreamweaver? You can't edit a website in Photoshop, it's an image editor. Dreamweaver is a web development editor: you can open your site resources in it, view them in design view if desired, and edit them there. Though honestly, I find it … | |
Re: Where's your form code? PS - you should probably be using mysqli: http://php.net/manual/en/book.mysqli.php | |
| |
Re: How are you checking for "all"? If your requirement variable for "country" isn't set, meaning it should accept all countries, then [icode]if($myCountry == $taskCountry)[/icode] won't work because [icode]$taskCountry[/icode] is not set to anything. For example, if [icode]$myCountry[/icode] is set to "USA" then you will be attempting to validate [icode]"USA" == … | |
Re: Are you sending caching headers? You can check in the Net/Network panel of your browser dev tools when you view the site... | |
Hi folks, I have a situation that's most easily explained via example, I think. So here goes. Let's say I have the following URLs: 1. /page.asp?id=123 2. /page.asp?id=123&category=ABC 3. /page.asp?id=123&category=ABC&var3=X&var4=Y I need these pages redirected. Currently links 1, and 2 redirect correctly. Option 3 though can have an arbitrary number … | |
Re: Why not use page=0, page=1, etc. instead of start=8, start=16, etc.? This way the number of items you show per page can change, which is better user experience if your users want to load more items on a page. $items_per_page = (!empty($_GET['show'])) ? $_GET['show'] : 8; // user selection or … | |
Hi all, I'm wondering if anyone's had experience with the WordPress Importer tool. I'm having trouble importing my WXR file through the tool. It works well for the most part, but when I get to the author assignment section, there are some issues. Under Assign Authors I only see `Import … | |
Re: You can use the onclick attribute as pritaeas suggested, together with the JavaScript `confirm()` function to give a popup with Yes or No options: echo "<td><a href=\"delete_members.php?id=".$row['id']."\" onclick="return confirm('Are you sure you wish to delete this item?');">Delete</a></td>"; If the user clicks Yes, the function returns `true`, and the link is … | |
Re: Please don't take this the wrong way, but where are you getting this code from? This code needs some serious help. Opening tags that aren't closed, self-terminating DIVs that serve no purpose, using *input buttons* for main nav? I've been writing HTML for a while now and I've never seen … | |
Hello, I have a Macbook Pro w/ Retina display (A1502), running Win 7 on bootcamp. I also have 2 [LG 25UM64](https://www.google.com/shopping/product/264296052983113163) monitors. The optimal resolution for these monitors is 2560x1080. However, so far as I can tell I can only hit this resolution if I'm connected through HDMI, for which … | |
Re: You may want to store a delimiting character between each set of numbers. This way you can use the `explode()` function so you don't have to know exactly where one substring ends and another begins. For example, let's say you choose a comma `,` as your delimiter, your code is: … | |
Re: This would be really hard to do without knowing your platform, database schema, or any of your code. ![]() | |
Re: I think any site that collects login information should be using SSL. Most people will repeat the same login information (username/email, password, and that specific pairing), between multiple sites. If you request this information from a user, you should be protecting it. That said, my company's considering to switch over … | |
Re: Good topic. I haven't worked on too many big "from scratch" projects so I'm looking forward to some interesting responses here. For me, the first item is figuring out what the project is about, and if there's a cost-effective platform out there that I can use as a framework. This … | |
Re: Agreed, I'd go with a background image, especially since you're already using a fixed width so you know just how wide the image has to be. Notice how when you use box-shadow you get the shadow along the top as well -- you probably don't want that. You have to … | |
Re: Personally if you're using Apache I'd just use htpasswd with .htaccess | |
Re: Try this for `gallery_loader()`: // Updated gallery_loader with ability to loop through multiple DB results. public function gallery_loader() { $sql="SELECT * FROM gallery WHERE id=1"; // IF YOU LEAVE id=1 you will only retrieve a single image. This code will still work, though. $query=mysql_query($sql); $i = 0; $slides = array(); … | |
Re: Use jquery's `.css()` to get the current value of a style property for an element. Similarly, adjusting a style with `.css()` will apply it to the element as an inline style. http://jsfiddle.net/QSg6k/1/ | |
Re: I'm wondering if this is some new black hat trend? I've noticed a number of users on here recently that post (especially in the SEO forum) one- or two-line questions about items that their profile/sig indicate they should already know, and never follow up on responses. | |
Re: Well for starters in update-profile-action.php you refer to `$_POST["profileimg"]`, but the field in update-profile.php has `name="image"` Next, you don't access the image file with $_POST, you use $_FILES and associated indexes/functions. And you don't actually store the image in the database, you just store the path (or just the filename) … | |
Re: @Ajay, the id of the `<input>` and the `<a>` being the same shouldn't be an issue. If I'm understanding OP correctly, the `<a>` is supposed to replace the `<input>`, so there will not be duplication. @OP: The `value` attribute is not valid in an anchor tag, though I don't think … | |
Re: I think this is overcomplicated and we're mixing up terminology. There is no comma-separated array in your database. What you probably have is a string separated by commas, unless you're using JSON or `serialize()`. That being said, all you have to do is concatenate your ID onto the end of … | |
Re: Hi Alyssa, You have a header section already in your HTML. Why not just add an `<img>` tag to it with the logo? <div id="header"> <img src="path/to/my/logo.png" alt="Site Title"> <h2>Header</h2> </div> | |
Re: Try a website like codecademy.com or dash.generalassemb.ly, they have good beginner web design tutorials. You should have a firm grip on CSS before you start worrying about dynamic websites. | |
Re: Nice post, this is very clear and useful. Finding detailed examples on checkbox processing with PHP can often be elusive, so thanks for the post! Maybe one of the mods can update the post type. | |
Re: Macromedia Dreamweaver? It's been Adobe Dreamweaver for around 9 years now. Good HTML and CSS authors should know that instead of `<b>`, `<i>`, and `<u>` you should be using `<strong>`, and `<em>` these days, and use CSS to specify the element's appearance (such as underlining) rather than relying on default … | |
Re: The `:hover` function is working. Your `overflow:hidden;` rules are keeping the dropdowns from appearing below `#navsearch` | |
Re: Without researching into if YT & TW even support this, here are some things you'd need to accomplish this in theory: * YouTube API * Twitter API * Cron jobs Basically, you'll be pulling information from YouTube and Twitter, which means you'd probably need to access their API. Now assuming … | |
Re: Did you try altering the permissions under Properties > Security? You can also try using CHMOD by opening the terminal through the XAMPP control panel | |
Re: If you can adjust your CSS, change the height in the rule `#header .description` to `60px` | |
Re: Check the WordPress Codex and look into creating a custom WP Loop using query_posts(). Your page is the Updates page, so when you do `if(have_posts())` it will check what the content is for that page (i.e., what's in the textarea for that page in the WP backend). You need a … | |
Re: I didn't see a clickable background on the linked page either. If I had to do such a thing, I would probably create a DIV as the first thing inside the BODY, <body> <div id="clickable-bg"></div> and set its styles to position: fixed; width: 100%; height: 100%; cursor: pointer; background: transparent … | |
Re: This is really a matter for your legal department... Many companies will have clauses in their developers' contracts stating that any software developed while an employee of the company/organization is owned by the company/organization. So if a new developer comes in and then tries to steal the code, you can … | |
Re: Stupid question: Why don't you just redirect them to the desired page? You *could* use cookies to track if the user visited the page, or use a database field to flag if they have. | |
Re: The W3C Validators let you know if your site code adheres to the World Wide Web Consortium's open web standards. These rules are a set of guidelines that web browsers are suggested to follow to make sure that what developers code appears consistently similar throughout different browsers. The different sets … | |
Re: On regstate.php line 2 you have $id=$_GET['param']; But according to line 81 in reg.php your variable is called `id`. So line 2 in regstate.php should be $id=$_GET['id']; | |
Re: It probably means you're missing a semi-colon somewhere. Can't tell without seeing the code. Check your functions.php file. EDIT: I didn't look closely enough at the file path. This isn't the functions.php in your theme folder as I originally assumed. There might be something wrong with your WP installation. I'd … | |
Re: `$_GET['Code']` won't return anything -- your form action is to VER2.php, through POST. There's no query string for retrieving any $_GET data from the URL. I don't agree with the above statement to replace all your $_POST indexes with variable names. I'd use that if you were doing data validation, … ![]() | |
Re: Try using Y-M-D format, see if that works? SELECT startDateTime, endDateTime FROM jobs WHERE startDateTime BETWEEN '2013-11-19' AND '2013-11-20' | |
Re: If you follow ibrahim.alzein great revision, I'd replace any `echo('<script... window.location = pageurl.php ...');`. No reason to use JS for the redirects. Replace with: header("Location: pageurl.php"); Adding to the post above, now on your welcome page the first thing should be `session_start();`, and you can thereafter access the user's name … | |
Re: Just set an index in your session array: $_SESSION['isadmin'] = 1; Another thing you can do is use your session data to query the db. $mysqliobject->query("SELECT user_role FROM a_table WHERE user_name = {$_SESSION['username']}"); To avoid the attacks, make sure you sanitize anything you get from cookies... |
The End.