Jump to content

thewooleymammoth

Members
  • Posts

    768
  • Joined

  • Last visited

    Never

Posts posted by thewooleymammoth

  1. on of the uses would be for employers looking and my work and deciding if they want to hire me or not... thats the main one i can think of right now, but im sure there is another one.... just escaping me.

     

    Ill try that function in a minute logovendor and give you my results

  2. here is a function to do this btw. I figure if someone comes across this thread in a search or something i would make it easier for them

     

    //tidy function based on php.net example. Code has not been tested.
    function html_cleanup($html)
    {
    $config = array(
                'indent'         => true,
                'output-xml'     => true,
                'input-xml'     => true,
                'wrap'         => '1000');
    
    $tidy = new tidy();
    $tidy->parseString($html, $config, 'utf8');
    $tidy->cleanRepair();
    return tidy_get_output($tidy);
    }
    
    

  3. IMO it would be an awesome feature if there were a facebook updates type thing. instead of clicking new replies to your posts, it could just have some kinda notification when someone has replied to oen of your posts. Just a thought i had, thought i would share.

  4. The way i create my pages is: i put all the outgoing html into a variable and then at the end echo it all out. I had an idea the other day, I bet there is a function, class, or script, which takes html and cleans it up so its readable for humans. Ex:

    <?php
    $body ="<html><head></head><body><div></div></body></html>";
    $body = html_cleanup($body);
    echo $body;
    //should output
    ?>
    <html>
       <head>
       </head>
       <body>
          <div>
          </div>
       </body>
    </html>
    

    Im looking for the html_cleanup() function. just wondering if anyone does the same and what they do. Or if they dont like the idea and why they dont. Thanks

  5. long load time, alot of images. Also not a fan of the border color, but thats opinion.

    Also the link backgrounds move rather slow for me. if thats css you should preload the images, if its js then perhaps there is a more efficient way of doing it. Cause i have a pretty nice internet connection and pretty nice computer, things rarely lag for me.

  6. no its in a school i am in for a web design certificate. This class is about the difference between designing a regular site and an e-commerce site.

     

    Thanks for the comments. Its too late to actually change them but ill keep those things in mind for future templates. Really i was more just curious about what you guys would think.

  7. "easier and less complex to just write out a paragraph of html"

     

    Ok, but this class only start to make sense when your dealing with dynamic content. Consider these examples:

    You have a breadcrumb div at the top of the page. Later on you decide to add in some content. But you already echoed out the breadcrumb. How do you change it without storing it somewhere along the way so that you can change it?

    Or wait I can come up with an even better example: You decide to add an external javascript or page title as the very last thing. These things wont be a problem if you use this class.

     

     

     

    I like the idea with the css function, but I think it goes against the structure and purpose of the class. Right now I'm trying to think of a way to include a helper function instead though, would be pretty sweet, but it wouldn't be possible to make one liners like this:

     

    div { font-size: 0.8em; font-style: italic; }

     

    What colors do you find is hard to read? The gray ones?

     

    Maybe i am mis-understanding... but if i decide later that i want to add JavaScript to the page i just scroll up and do it...? same with breadcrumbs...? besides, if someone else were breaking down your code and trying to decipher whats going on, it would be really hard to scroll through the whole page to find where you added what in if you were just adding them in whatever order they came into your head.

     

    also i like that associative way as well for the css. and i dont see why it wouldnt be possible to have one liners in there either way

    <?php
    $css = array(
    'div' => array(
    	'background'	=>	'#ff0080',
    	'border'	=>	'1px solid green',
    ),
    '#specific_div' => array(
    	'background'	=>	'white',
    )
    );
    function css_compile($css)
    {
       foreach($css as $resource=>$block)
       {
           $str.=$resource." {";
           foreach($block as $prop=>$val)
           {
               $str.=$prop.": ".$val.";";
           }
           $str.="}"
       }
       return $str;
    }
    ?>
    

  8. Its cool, and im sure it took a while to write. But i dont know if a lot of people will use it because its alot easier and less complex to just write out a paragraph of html...

     

    i mean, look at your example vs.

    <style>
    
    		div {
    			background: #ff0080;
    		}
    
    	</style>
    	<span>As easy as:</span><br />
    	<ul>
    		<li>One</li>
    		<li>Two</li>
    		<li>Three</li>
    	</ul>
    	<div>
    		<i>This goes after everything else.</i>
    	</div>
    

    your class would require a lot of thinking, arrays, classes, #of code lines (i like to use as few as possible), syntax etc..  Where simple html is exactly that, simple. Not to say that people wont use it, i just dont think it will explode.

     

    as for the class, it seems pretty cool and well written, but there is one thing i would change. for the css method, couldnt you make it so that the brackets are added automatically?

    $css = array(
    	"div {",
    	array(
    		"background: #ff0080;"
    	),
    	"}"
    );
    // could be
    $css = array(
    	array(
                            "div",
    		"background: #ff0080;",
                            "border: 1px solid green;"
    	),
                   array(
                           "#specific_div",
                           "background: white;"
                   )
      );
    

     

    and just use the first element in the array to start the block.

     

    Also i think you should change your site colors a little, its kinda hard to read.

     

  9. mmm sorry but i just dont see what advantage this has too:

    <?php
         echo "
                  <table>
                     <tr>
                         <td>
                               some stuff
                         </td>
                    </tr>
                  </table>
                 ";
    ?>
    

     

    and the page doesnt really explain. it just says that it cleaner somehow.

  10. you have some good points. I like to make my links from images though cause they can be alot fancier especially with rollover. Unless of coarse there is going to be alot of page changes.

     

    I had actually already thought of using the background image as a slideshow and i think its a pretty good idea. Except i am going to make it so you can move the divs with the content away so that you can see the picture. similar to how you can move them away on http://script.aculo.us/ except mine will stay where you put them. I was also thinking of having it scroll through the different images periodically. but all that may simply be too much cheesiness. Ill see once i make it.

     

    as for the current picture, I dont think that they have any real pictures. As far as i know they are pretty much a run of the mill landscaping company. So i dont think that the background picture shouldn't look like an amazing lawn, because thats what people usually want when they look for landscaping.

     

    Thanks for the comments.

  11. Nope haha, just a couple of quincidences. haha not going green. i got an 900w power supply and i love every one of em.

     

    Do you think there is too much green or not enough of anything else? Ill play around with it a little

×
×
  • 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.