Jump to content

falkencreative

Advanced Member
  • Posts

    4,419
  • Joined

  • Last visited

  • Days Won

    27

Posts posted by falkencreative

  1. I can't really comment on "reasonable costs", since it depends on so many factors... the server you get, the space/memory it has, the connection to the internet, etc. 

     

    But yes, you could rent a server and then sell server space to host other websites on.

  2. In general, you want to make your code as simple and as straightforward as possible, so make sure you're not adding in unnecessary elements.

     

    From a styling perspective, it shouldn't really matter significantly. From a functionality perspective, you'll often see wrapper divs because a developer wanted to have one element that had a set width that would contain the entire site (often to center position it in the browser).

  3. Probably the easiest way would be to make the logo a background image on your .logo h1, rather than using an img tag. Then, you can easily switch between the two versions of the logo by using media queries targeting device width.

  4. It really isn't possible to know based just on that screenshot. I'm not seeing anything wrong as far as I can tell. It's possible the issue is earlier in the file. That said, if you aren't getting any errors when running the code in the browser, I wouldn't worry about it that much.

  5. The Cinema display is the next on my list now that I (recently) purchased a new laptop (I currently use an older 23" Apple display). I might try to wait a bit (at least till the big Apple event in June?) to see if they come out with a new version. The current display was launched in Sept 2011, so it's overdue for an update. Might be nice if it added additional ports and/or at least upgraded to USB3.

  6. I'd suggest watching the "PHP and Javascript Form Validation" series. While it covers building a contact form, rather than a survey form, you'll be using the exact same approach and techniques when building your form.

    • Upvote 1
  7. Here's a rough sample that I would like to see:

     

    http://my.jetscreenshot.com/22574/20140327-p2f4-89kb.jpg

     

    This is much easier for me to read than other.

     

    I've put a sample Dark theme in place for you (Theme Change in the bottom left corner of the forum > "KillerSites Dark Theme"). It isn't a complete reskin, since doing that would take a pretty huge amount of time. However, I have themed a lot of the basic conversation functionality, so hopefully that will be helpful. If there's anything that isn't readable, let me know.

  8. So I looked into this. Setting a product to "0" is fine... as long as it isn't the only item in the cart. Basically, the issue is that the $_SESSION['cart'] could wind up being empty... and the mysqli queries didn't know how to handle an empty array. 

     

    Update m_cart.php:

    public function update($id, $num) 
    {
        if ($num == 0)
        {
            unset($_SESSION['cart'][$id]);
            if (empty($_SESSION['cart'])) { unset($_SESSION['cart']); } //add
        }
        else 
        {
            $_SESSION['cart'][$id] = $num; 
        }
    }

    The fix in this case was to check if the session variable is empty, and if so, unset the cart so there are 0 items in the cart. 

     

    Hope that helps.

  9. Looks like the problem is that the defaults between those two functions are different. By default, the getData() function within the login tutorial returns the variable, whereas the default getData() function from the shopping cart tutorial echos the data.

     

    With that in mind, and considering that the login functionality involves less code, I would suggest using the getData() function from the cart tutorial, and make sure to pass "FALSE" in as the second parameter in any instances of getData() within the login code where you need to return the data rather than echo it out.

     

    My apologies about the default functionality changing -- I didn't even realize that till just now. I'm not completely sure why it changed, it's just what made sense to me at the time when I was developing it.

  10. @eddie - There is a "View Unread Posts" option (main navigation, top right). That gives you options for viewing posts you haven't seen yet, with time-based limitations so you can look at the last 24 hours, week, etc. Does that do what you want?

  11. I've updated the forum to use the usual KillerSites greens rather than the forum's default blue themes. However, this is a relatively big piece of software with a lot of functionality, so if there's anything I missed, please reply or send me a PM so I can fix it. Thanks!

  12. I tried emailing you back, but I always got an error when trying to email your email address unfortunately.

     

    As for your question, I imagine it's not technically something that is wrong with the syntax, but that $items is either null or empty and the query doesn't know how to handle that (since that isn't an expected value). The first step would be do figure out what $items contains within the get() method when the error occurs, and then work back from there.

     

    I'd likely have to step through the entire logic of the page request to see how $items is set in order to resolve it. I'll see if I can take a look near the end of the week.

  13. At least for me, I use a Mac in my videos because that's what I have, and that's the platform that supports the text editor that I use. I'm a designer, and like a lot of designers, I use a Mac. At least for my videos (PHP primarily), the code I use should work and display fine no matter what platform the viewer uses.

     

    Which video course are you watching specifically? And what differences are you seeing?

×
×
  • Create New...