Jump to content

floridaflatlander

Members
  • Posts

    671
  • Joined

  • Last visited

  • Days Won

    1

Posts posted by floridaflatlander

  1. I've been working on this for a while and I can't figure it out.

     

    I'm wanting to get all the items in the products table and if they have a main photograph in the photos table get the photo info also.

     

    So when I echo the results I'll have all items without main photos displayed and all the items with main photos displayed.

     

    The tables I'm using are

    product

    id_prod | id_mem | title | publish

     

    photos

    id_prod | thumb | width | height | main_photo

     

    members

    id_mem | mem_group      (mem_group = active or banned)

     

    The sql I've been messing around with

    $q = "SELECT photos.thumb, product.id_prod, product.title, photos.thumb_width, photos.thumb_height
    FROM product, photos, members  
    WHERE product.publish = '1'
    AND product.id_mem = members.id_mem
    AND mem_group >=1 AND mem_group <100
    OR product.id_prod = photos.id_prod
    AND photos.main_photo  =  '1'
    ORDER BY product.id_prod DESC"; 
    

     

    Any help would be greatly appreciated.

    Thanks

    S

  2. I know I should have used the user number Id but I used the unique usernames to check for identity in the

    script. I don't want to change it now.

     

    You could also use the mem numbers in the url and echo the user name in the header or middle column somewhere. Then just remove it when you're through testing, if you're not going to use the user name in the url and you're testing it that way when you do remove it it will be just that much more stuff to check in the php code and sql. Just a thought.

  3. ................................  I have made the user profile edit page visible to the user when they log in, and I think I can get away with not showing the user their "public" profile view. But I definitely need to show other users on the site the "public" non editing profile page view. ..........

     

    I'd have "one public page" with the user redirected to that page/file after editing so they can see the changes. For the user I'd have a link on his public profile or in a menu somewhere where they could click edit and go back to their edit_profile page if needed. That's simular to what I've done here Link

  4. The left side is a simple relative div which contains 4 thumbnails. On the right side, though, there are 4 absolute divs placed one over another in which I put some text and real-size images. To each thumbnail I ascribed a behaviour show-hide element, so basically, when you click the first thumbnail, one absolute div (containing elements relative to the first thumbnail) appears while the other 3 get hidden. I repeated this action for every thumbnail.

     

    LOL you jury rig like me.

     

    I suggest that you go to http://www.dynamicdrive.com/ there is a java script that I got from there that I use.

    It loads the thumb nails and when you click them they appear in their own div and I let php decide which pics and text to load and if you enter text the text will be under the pic, I have my text styled to be on the side. I can't remember the name of the one I use but you can look and see all kinds there. I'll see if I can find the name of the one I use and post it if I get a name.

     

    As stated be very careful of absolute, load your site in firefox and use the control + & - keys to increase font size and try to tear the div up. See what happens.

  5. Just be aware that PHP 6 does not exist.  All of its features have been added (or will be added) in 5.3+.

     

    About a year ago I saw a post by Larry Ullman on his forum and to me it insinuated that he was embarrassed because he had used php6 in the title of one of his books. I guess it's a competitive business and trying to be the first one out of the block with a php6 book was a gamble that went bad.

  6. Here is a post I made in another topic early last week.

     

    I think it depends on where your at in your coding experience, to give you an idea of where I'm coming from I'm over 50, messed around with stuff like debase II, debase III and debase III+ and paradox in the late 80's and very early 90's. Then dropped out of any kind of coding for twenty years. I think the brain changes when you use it different ways so when I started back last year to playing with code I had a very hard time.

     

    I first bought Ullman's php6mysql5 and went what? I then bought ullmans very beginner PHP book and learned from that and then went to Ullmans php6mysql5. I have several other books that I got and that come in handy for reference but time will tell. When you start building things that's when you really learn.

     

    If you can code a little I'd suggest Ullman's php6mysql5 or Welling & Thomson's Php & Mysql.  Also go to amazon and read the reviews.

     

    Now there are people that are on here that say they have never used a book to learn php, I have and idea it has to do with smarts, social environment and age(some generations just play with this more than others).

     

    I'm not a fanatic, guru or freak but these books teach the basics, are still good and you can use all of their code today.

  7. You shouldn't change their actual password until they visit the reset page and do it themselves. The reason is because anyone could say the password is lost,

     

    Interesting

    Now I have it where a user goes to forgot-password.php, enters their email and a new md5 password is sent to them.

     

    I was thinking if someone was enterested in a product, contacted the owner, didn't like the converstation, got mad and then just for kicks went to forgot-password.php and entered the owner of a products email(which they would get from emails back and forth about the product or service) and then resets the owners password. (That would be a b....)

  8. I think it depends on where your at in your coding experience, to give you an idea of where I'm coming from I'm over 50, messed around with stuff like debase II, debase III and debase III+ and paradox in the late 80's and very early 90's. Then dropped out of any kind of coding for twenty years. I think the brain changes when you use it different ways so when I started back last year to playing with code I had a very hard time.

     

    I first bought Ullman's php6mysql5 and went what? I then bought ullmans very beginner PHP book and learned from that and then went to Ullmans php6mysql5. I have several other books that I got and that come in handy for reference but time will tell. When you start building things that's when you really learn.

     

    If you can code a little I'd suggest Ullman's php6mysql5 or Welling & Thomson's Php & Mysql.  Also go to amazon and read the reviews.

     

    Now there are people that are on here that say they have never used a book to learn php, I have and idea it has to do with smarts, social environment and age(some generations just play with this more than others).

  9. I suggest you get use Firefoxes Firebug. It is a God send, I think Chrome does the same thing. I can't see working without either. Anyway you open firebug, find the html code you have questions about or want to edit, click the tag and firebug will tell you where the style is coming from(example: index.css line 250), it will color the div or tag and then it colors the padding and magins so you can really see whats what and it will also show the heredity of the tag and their line numbers.

  10. Better lighting and angles would go a long way as well.

     

    Her lighting sucks as well as the compostion of the photos and that's an understatement.

     

    Like KingPhilip wrote, "show them", I know it can be hard but it's for their own good. To me the pictures you say they want are very bad. They're okay to send home and say this is what I ate today mom but for selling to other people, no.

  11. but when i submit the form ..... the result i get is 'Submit Query' which is the value of the button...

     

    You may need to post the code, you are submitting it aren't you.

     

    But I use if (isset($_POST['submitted'])) {

    run this code

    }

     

    To block things off.

  12. Get and use firefoxe's fire bug, it will help you analize your site and others peoples site with ease. It is a God send. I believe the problem must be with the div with the text that looks good to me  (is there really a space between wrapper & article) the text should auto wrap.

  13. Thanks

     

    I've played with - if (isset($_FILES['image']) && ($_FILES['image']['error'] == UPLOAD_ERR_OK)) - from several angles and that may have done it. I think this is like error 4, no file uploaded

     

    I'll come back tomorrow and give an update after I play with it for a while.

     

    I don't under stand why (isset($_POST['news_info'])) && (isset($_FILES['image'])) are different, but I'll address that later, anyway thanks again.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.