344 Posted Topics
Re: You need to find out which classes/ids to style. Use firebug or some other browser developer tool to inspect the element you want to style, then check the class or ID and use CSS selectors to make the changes. | |
Re: I'm not seeing distortion on the homepage either. Could you submit a screenshot? | |
Re: I'd probably make multiple images for each set of texts & arrows, then use CSS background images to change which one appears on a given page. | |
Re: You can try adding the following after the closing brace at line 42: else if(strstr($ua, 'android') && strstr($ua, 'mobile')) { // check if android mobile $b[] = 'android mobile'; } else if(strstr($ua, 'android') && !strstr($ua, 'mobile')) { // check if android tablet $b[] = 'android tablet'; } A couple of … | |
Re: The end of Line 11 has `$SQLstring = "USE $DBName";` -- this should be bumped down to a new line, as it stands it is commented out. I don't see the point of setting the database or table in Count Visits, if you already create a table in ngarrett_MIS4530A through … | |
![]() | Re: An issue I see that may be related: > values (id,'$name','$surname','$email','$password','$date')"; If your ID is auto-populated via AUTO_INCREMENT, you shouldn't be including it in your INSERT statement: $qry = "insert into users(name, surname,email, password,date) values ('$name','$surname','$email','$password','$date')"; Alternatively, if you're manually assigning IDs, then `id` in the quoted text should be … |
![]() | Re: According to [quirksmode](http://www.quirksmode.org/css/condcom.html), the syntax for !IE should be: <!--[if !IE]> --> <link href="style.css" rel="stylesheet" type="text/css" /> <!-- <![endif]--> You wouldn't happen to have a URL we could check, would you? ![]() |
Re: I think you need to brush up on your understanding of the [box model](http://www.w3schools.com/css/css_boxmodel.asp). > when i define the body element with width=970px by default the right margin does not restrict itself to the width of the body Margins are not supposed to restrict themselves based on width. Margins goes … | |
Re: If you're just using a single CSS file (or even a bunch, but all the in the same directory) and all images are in the same directory, using relative paths should be easy. As JorgeM said, use a forward slash at the beginning of your path to start at the … | |
Re: The image on the Twitter backgorund right now is: https://abs.twimg.com/a/1363712241/t1/img/front_page/cricket@2x.jpg As you can see, it's actually not a very large image, at 1040x660, with a file size of 86KB. They use CSS to expand the image thereafter, which is why you'll notice the image is lower quality on big screens … | |
Re: Your function probably doesn't know what `$(this)`. Try passing it as a parameter maybe? function pic_shift(square){ $("#testit").removeClass("main_page"); if ( square.hasClass('active') ) { /* actions here */ } else if ( square.hasClass('one') ) { /* actions here */ } else { alert('error - nothing found'); }; } $('.square-container').on('click', '.square', function(event) { … | |
Re: Take lines 2-4 and line 7 from the MC code and drop them in at line 23 of header.php (i.e., right before `wp_head()`). Then on line 60 of header.php change <div id="header-search" class="group"><?php get_search_form(); ?></div> to <div id="header-search" class="group"> <div id="mc_embed_signup"> <form action="http://rjthompsonmusic.us4.list-manage.com/subscribe/post?u=86729b354d1a75a35e8fd9771&id=bd9f282fc3" method="post" id="mc-embedded-subscribe-form" name="mc-embedded-subscribe-form" class="validate" target="_blank" novalidate> <label … | |
Re: The concatenation operator in PHP is `.`, not the `+` that you might use in JavaScript or some other languages. So all the `+`'s you use in your strings above are just performind mathematical operations. http://php.net/manual/en/language.operators.string.php | |
Re: > The class file ArtxContent.php is located at /public_html/templates/lpl3/classes/ArtxContent.php and defined in the classes.php file... You mean _included_ in classes.php, yes? What is the path for classes.php? | |
Re: I agree with using `.on()` instead of `.each()`. Just a note, `data-` attributes are HTML5, so if you are writing your page in XHTML for some reason, it will be invalid markup. | |
Re: Haven't tried it, but what about instead of `'.square' || '.main'` you use `'.square, .main'`? | |
Re: Disclaimer: I don't have a ton of experience designing DB schemas, and in fact my SQL is rusty, so I'm actually just putting this out there because I want to know others' thoughts. I'd probably go about this having 3 tables: *players* * id * name * username * etc. … | |
Re: I agree with JorgeM. I generally avoid using absolute positioning. The nature of the property does not allow flexibility of course, so this makes this less useful for sites serving up dynamic content, in which element sizes can change from page to page. One instance where you might use absolute … | |
Re: I'm not well-versed in mobile dev -- Is there any reason for the absolute positioning on #content? | |
Re: pritaeas is saying that instead of `$search = 'iphone';` you should be using the result of your search form on the right side of the `=`. It depends on the code for your search form. What is the name or ID of your textbox? | |
Re: If you can get the URL in text all you have to do is put it into an HTML `<img>` tag: <img src="<?php echo $row['image']; ?>" alt="your alt text" /> | |
Re: > I quit using the $_POST a long time ago... found it was unnecessary and just more confusing to look at. This is either false or an incomplete statement in that you are not providing/aware of full information regarding what's going on. There are several ways that come to mind … | |
Re: Building off <MICHAEL>'s response, if I were you I'd use Firebug to check out and play with the styles on the div with ID "toolbar" and see what turning different options on and off does. This will give you a feel for how it was created. | |
Re: Several people mentioned WAMP or XAMPP, but it wasn't really explained what the purpose of these is. They're essentially packages of Apache, MySQL, and PHP (+ more, but these are the main items we're interested in here) which will allow you to develop locally on your machine. You can then … | |
Re: > The date() function takes two arguments. The first argument specifies the date format you want the timestamp to be converted to. The second argument specifies the timestamp that will be converted. Without the second argument, how does the date() function know what the date is? The second argument for … | |
Re: I've had a similar train of thought recently myself. Often I see answers that consist of nothing more than links to Stack Overflow discussions or articles/discussions on other websites. I think this hurts DaniWeb. From an SEO standpoint, in essence we are generating less unique, high-quality content for DW and … | |
Re: Try adding z-index to make the element come to the front .footer2 { width:100%; position:fixed; left:0; bottom:0; background-color:#CCCCCC; border:1px solid #666; text-align:center; z-index: 1000; } | |
Re: I've been with Dreamhost for a couple of years now, and while I don't have to interact with their control panel as much anymore, they get big props in my book for not using cPanel. | |
Re: You want a link that links back to the same page, but with an extra variable tacked on? Did I understand correctly? <?php $thisPage = htmlentities($_SERVER['PHP_SELF']); $hasVar = strpos($thispage, '?'); if($hasVar === FALSE) // Check if there is already a variable on the URL $url = $thisPage . '?two=bar'; // … | |
Re: Not sure what you mean regarding outputting a table, I don't know what the contents for your table are or where you're grabbing them from. The following script should help you get the expected graduation year with JS, though: <input type="text" id="currentGrade" /> <input type="submit" id="getGradYear" onclick="expectedGradYear(); return false;" /> … | |
Re: Why is there a semi-colon at the end of the line your `if` statement is on? Also your do_shortcode part doesn't seem to make sense. No reason to put <?php ?> in there. Try: echo do_shortcode('[testimonialswidget_list tags="'.$this_tag->name.'" limit=2]'); Note I haven't tested and have never worked with this widget or … | |
Re: The issue seems to be one of speed, as JorgeM indicated. The problem is that the JavaScript that makes your "Featured" slider work loads after the rest of the page, so it can't make the slides disappear until then. A solution I usually use is to have the default styles … | |
Re: I'm not seeing that page when I view on mobile. The design is totally different on my phone. Based on the screenshot, however, my assumption would be that the div wrapping the form either needs more width or less padding, or maybe both. | |
Re: Form validation should take place on the *server* side. So the answer to your question really depends on what server-side language you are using. You can add JavaScript form validation to make your form look pretty, but if you don't have server-side validation and the user turns off JS in … | |
Re: If you are using relative links, use `..` to indicate the level above. So to link from index.htm to home.htm: <a href="../folder2/home.htm">link to home</a> To link from home to index, do the same but replace folder2 with folder 1, and home.htm with index.htm. | |
Re: You could run this query first to get how many tables you'd need: SELECT COUNT(DISTINCT group) FROM my_table; | |
Re: How about <script type="text/javascript"> function printAndCheck() { print.window(); var success = confirm("Did it print successfully?"); if(success) window.location.href='logout.php'; else window.location.reload(); } </script> and change your onclick to onclick="printAndCheck();" Haven't tested but I think it should work. | |
Re: Haven't had a chance to go into your code much, but first off ditch the regex's and use `mysqli_real_escape_string()` instead: [PHP Manual Entry](http://us2.php.net/manual/en/mysqli.real-escape-string.php) EDIT: Just to clarify, you can clean up your query and make it much easier to read -- if($_POST['submit']) { $typeid = $db->real_escape_string($_POST['cat']); $title = $db->real_escape_string($_POST['title']); $summary … | |
Re: Sounds like OP is trying to make a PHP desktop app. You may want to read up on this to make sure it's how you want to follow through, as the general consensus seems to be that there are far better options: http://stackoverflow.com/questions/40870/why-dont-people-use-php-for-desktop-applications Further, you can't natively use JS for … | |
Re: Proglearner, are you referring to a `<textarea></textarea>`? [Textarea at w3schools](http://www.w3schools.com/tags/tag_textarea.asp) You can set the width and height via CSS or the rows and columns via HTML attributes. Whether or not it is a security hole for DoS or whatnot really depends on your form processing code. | |
Re: Have you tried [Firebug](http://getfirebug.com/)'s Script tab? | |
Re: > use 'include' not 'require_once' Not sure this will help, since "include" and "require" are almost the same thing, except "require" will kill the script if the file is not found. aglaf1979, Do you have error messages turned on? Are you getting any errors when you try to include the … | |
Re: Hi dancks, Nice undertaking! Best way to learn in my opinion. Your code is only using `width: 630px` for the containing divs. There's nothing to push the inside elements/divs away from the walls of their respective containers. On the YouTube page, they are using paddings on the containers to push … | |
Re: Remove the quotes from max(period_id). | |
Re: Not really sure what you're looking for here. Could you elaborate? Every `<option>` tag needs a corresponding closing `</option>` tag, but you only have one. Change line 15 to `$options.="<option value=\"$id\">".$state."</option>;` Then change line 19 to <select name="listing"> <option value="0">Choose</option> <?php echo $options; ?> </select> | |
Re: Line 36, change `value=<?php echo $refId; ?>` to `value="<?php echo $refId; ?>"`. I don't think that'll solve it but you should have the quotes there. Same for the `href`s on line 40. Can you provide your code on the next page that includes `$_POST['refID']` and how you process it? Make … | |
Re: AleMonteiro is correct. The way you originally put the variables in does not replace them with their values in the echo statement. If you want to stay with single quotes, you need to use the concatenation operator (`.`) as shown above. If you want to put the variable in without … | |
Re: If I understood you correctly, maybe this will help: $('.tables_stats').each(function() { var table_name = $(this).attr('id'); switch(table_name) { case "[table_id_here]": // change to the table name you're checking for run_a_fcn(); break; // etc. } }); Hope that helps. ~ EF | |
Re: OK I'll try to clarify, since this thread keeps getting dug up from the grave: `<pre>` isn't a one-off solution for getting line-breaks in your code. "The pre element represents a block of preformatted text, in which structure is represented by typographic conventions rather than by elements" (http://www.w3.org/TR/html-markup/pre.html) If you're … |
The End.