SitePoint Sponsor

User Tag List

Page 2 of 5 FirstFirst 12345 LastLast
Results 26 to 50 of 118

Thread: wordpress

  1. #26
    SitePoint Evangelist
    Join Date
    Feb 2009
    Posts
    412
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    hello,

    so i installed the template that i was working on and now i get this problem were no images are shown and the css doesn't seem to function. please help:

    www.polar-pos.com/blog/


    what is going on?

  2. #27
    Is Still Alive silver trophybronze trophy RetroNetro's Avatar
    Join Date
    Jul 2003
    Location
    Texas
    Posts
    6,883
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    I notice you have links to 2 style sheets in the head:
    Code HTML4Strict:
    <link href="css/index.css" type="text/css" rel="stylesheet" />
    <link rel="stylesheet" href="http://www.polar-pos.com/blog/wp-content/themes/awp/style.css" type="text/css" media="screen" />
    The first one returns a 404 error and the second one is the default theme style sheet.

  3. #28
    SitePoint Evangelist
    Join Date
    Feb 2009
    Posts
    412
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    no i renamed index.css to style.css but it still won't work

  4. #29
    Is Still Alive silver trophybronze trophy RetroNetro's Avatar
    Join Date
    Jul 2003
    Location
    Texas
    Posts
    6,883
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    You need to replace the default .css file with the .css file you have made for your layout. It goes in the active theme folder. You need to make sure that the file has the following at the top of it: http://codex.wordpress.org/Theme_Dev...me_Style_Sheet

  5. #30
    SitePoint Evangelist
    Join Date
    Feb 2009
    Posts
    412
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by BPartch View Post
    You need to replace the default .css file with the .css file you have made for your layout. It goes in the active theme folder. You need to make sure that the file has the following at the top of it: http://codex.wordpress.org/Theme_Dev...me_Style_Sheet
    i done that exactly, in the same folder were it has index.php i have style.css with that at the top.

    the image folder doesn't work as well there is something up.

  6. #31
    Is Still Alive silver trophybronze trophy RetroNetro's Avatar
    Join Date
    Jul 2003
    Location
    Texas
    Posts
    6,883
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Looks like it is at least partially sorted.

    The images, are here: /blog/wp-content/themes/awp/images/future_slide.jpg

    But the file is looking for them in the root of your blog install: /blog/images/future_slide.jpg

    What additional problems are you having?

  7. #32
    SitePoint Evangelist
    Join Date
    Feb 2009
    Posts
    412
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    that is really weird the code just says images/whatever-image.jpg

    i checked other templates that's how they got it setup :X

  8. #33
    SitePoint Evangelist
    Join Date
    Feb 2009
    Posts
    412
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    how can i fix tha tissue?

  9. #34
    Is Still Alive silver trophybronze trophy RetroNetro's Avatar
    Join Date
    Jul 2003
    Location
    Texas
    Posts
    6,883
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by silver163 View Post
    how can i fix tha tissue?
    To correct the path to the images. You can either hard code the URLs in there: http://yourdomain.com/blog/wp-content/themes/awp/images/future_slide.jpg or you can use this template tag:
    Code PHP:
    <?php bloginfo('template_directory'); ?>
    so it would become:
    Code PHP:
    <?php bloginfo('template_directory'); ?>/images/future_slide.jpg

  10. #35
    SitePoint Evangelist
    Join Date
    Feb 2009
    Posts
    412
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    awesome great!

  11. #36
    SitePoint Evangelist
    Join Date
    Feb 2009
    Posts
    412
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Several questions:

    I got the categories setup and I have a css setting written up which declares a "current" category. If the user is reading a single blog post in that category or browsing in that category how can i set it that the css "current" class is activated for that particular category? can that be done?

    Also I see there is a search function within Wordpress and it provides its own search textbox and search button but is there way to use the code I written out:

    Code:
    <div id="search">
            <form action="#" method="post">
                <fieldset>
                    <div class="search-input-bg">
                        <input type="text" class="search-input" value="search" name="search" 
                        onfocus="if(this.value=='search') {this.value='';}" onblur="if(this.value=='') {this.value='search'}" />
                    </div>
        			<div class="form-button"><span><input type="submit" value="GO" name="go" /></span></div>          
                </fieldset>
            </form>    	
        </div>

  12. #37
    Is Still Alive silver trophybronze trophy RetroNetro's Avatar
    Join Date
    Jul 2003
    Location
    Texas
    Posts
    6,883
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    By default the wp_list_categories() function adds a class of "current-cat" to the current category. So you can use this: li.current-cat { ... }

    http://codex.wordpress.org/Template_...Category_Lists

    The search? Yes just paste this into searchform.php:
    Code:
    <div id="search">
     <form action="<?php echo $_SERVER['PHP_SELF']; ?>" method="post">
      <fieldset>
       <div class="search-input-bg">
        <input type="hidden" name="s" value="1" />
        <input type="text" class="search-input" value="search" name="s" id="s" onfocus="if(this.value=='search') {this.value='';}" onblur="if(this.value=='') {this.value='search'}" />
       </div>
       <div class="form-button"><span><input type="submit" value="GO" name="go" /></span></div>          
      </fieldset>
     </form>   	
    </div>
    The only things I changed are:
    1. the form action: <?php echo $_SERVER['PHP_SELF']; ?>
    2. I added this line as I think it is required: <input type="hidden" name="s" value="1" />
    3. I added name="s" id="s" to the input as I think they are also required.


    http://codex.wordpress.org/Creating_a_Search_Page

  13. #38
    SitePoint Evangelist
    Join Date
    Feb 2009
    Posts
    412
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by BPartch View Post
    By default the wp_list_categories() function adds a class of "current-cat" to the current category. So you can use this: li.current-cat { ... }

    http://codex.wordpress.org/Template_...Category_Lists

    The search? Yes just paste this into searchform.php:
    Code:
    <div id="search">
     <form action="<?php echo $_SERVER['PHP_SELF']; ?>" method="post">
      <fieldset>
       <div class="search-input-bg">
        <input type="hidden" name="s" value="1" />
        <input type="text" class="search-input" value="search" name="s" id="s" onfocus="if(this.value=='search') {this.value='';}" onblur="if(this.value=='') {this.value='search'}" />
       </div>
       <div class="form-button"><span><input type="submit" value="GO" name="go" /></span></div>          
      </fieldset>
     </form>   	
    </div>
    The only things I changed are:
    1. the form action: <?php echo $_SERVER['PHP_SELF']; ?>
    2. I added this line as I think it is required: <input type="hidden" name="s" value="1" />
    3. I added name="s" id="s" to the input as I think they are also required.


    http://codex.wordpress.org/Creating_a_Search_Page
    sweet!

    thanks i appreciate it. but there is two files:

    archive.php and archives.php

    but codex just refers to archives.php

    is there any difference?

  14. #39
    Is Still Alive silver trophybronze trophy RetroNetro's Avatar
    Join Date
    Jul 2003
    Location
    Texas
    Posts
    6,883
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Yes. archive.php is for displaying categories, date, author and such post pages and archives.php is for a page that lists your archives by category, date, author and so on (kinda like in the sidebar.php file)

  15. #40
    SitePoint Evangelist
    Join Date
    Feb 2009
    Posts
    412
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by BPartch View Post
    Yes. archive.php is for displaying categories, date, author and such post pages and archives.php is for a page that lists your archives by category, date, author and so on (kinda like in the sidebar.php file)
    ok so i am working archive.php (don't really need archives.php)

    and for each post I want the setup to be in this html original code:

    Code:
                    <li>
                    	<div class="news-date">21.06.2009</div>
                        <a href="#" class="news-item">Innova Construct opens itís new headquarters in Los Angelos</a>
                    </li>
    is this the correct translation?

    Code:
    <li>
                    	<div class="news-date"><?php the_time('l, F jS, Y') ?></div>
                        <a href="<?php echo $guid; ?>" class="news-item"><?php the_title(); ?></a>
                    </li>

  16. #41
    Is Still Alive silver trophybronze trophy RetroNetro's Avatar
    Join Date
    Jul 2003
    Location
    Texas
    Posts
    6,883
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    What is: <?php echo $guid; ?> ?

    Other than that it looks good but I might just not know what this is.

  17. #42
    SitePoint Evangelist
    Join Date
    Feb 2009
    Posts
    412
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by BPartch View Post
    What is: <?php echo $guid; ?> ?

    Other than that it looks good but I might just not know what this is.
    that should be the URL.

  18. #43
    Is Still Alive silver trophybronze trophy RetroNetro's Avatar
    Join Date
    Jul 2003
    Location
    Texas
    Posts
    6,883
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    While that may be completely valid and if it's working than it must be good to go. Though I'm used to <?php the_permalink() ?> for the URL.

  19. #44
    SitePoint Evangelist
    Join Date
    Feb 2009
    Posts
    412
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by BPartch View Post
    While that may be completely valid and if it's working than it must be good to go. Though I'm used to <?php the_permalink() ?> for the URL.
    doh alright. i guess that is how it is supposed to be cause were i used that php code snippet was for my point of sale page. if you see at the bottom it is pulling the newest posts.

  20. #45
    Is Still Alive silver trophybronze trophy RetroNetro's Avatar
    Join Date
    Jul 2003
    Location
    Texas
    Posts
    6,883
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Yeah the reference I found to that snippet was for a latest post widget.

  21. #46
    SitePoint Evangelist
    Join Date
    Feb 2009
    Posts
    412
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    how can i set the different pages for the archive.php file? for example if there is more than one page it will post like here in the html version:

    Code:
                <div class="pagination">
                    <ul>
                        <li><a href="#" class="button"><span>1</span></a></li>
                        <li><a href="#" class="button active-pag"><span>2</span></a></li>    
                        <li><a href="#" class="button"><span>3</span></a></li>
                        <li><a href="#" class="button"><span>4</span></a></li>                    
                    </ul>
                </div>
    how can i convert that to the proper PHP language?

  22. #47
    Is Still Alive silver trophybronze trophy RetroNetro's Avatar
    Join Date
    Jul 2003
    Location
    Texas
    Posts
    6,883
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    There is this plugin: http://wordpress.org/extend/plugins/wp-page-numbers/

    Though I might be misunderstanding what you're asking. If so, just let me know.

  23. #48
    SitePoint Evangelist
    Join Date
    Feb 2009
    Posts
    412
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by BPartch View Post
    There is this plugin: http://wordpress.org/extend/plugins/wp-page-numbers/

    Though I might be misunderstanding what you're asking. If so, just let me know.
    no what i meant was if let's say i search through an archive and is there a limit of posts it will show before going to the next page?

  24. #49
    Is Still Alive silver trophybronze trophy RetroNetro's Avatar
    Join Date
    Jul 2003
    Location
    Texas
    Posts
    6,883
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    You're asking how to limit the number of posts that appear on an archive page? If so, this is under settings > reading > number of posts to display or something similar. This will also limit the number of posts on the main posts page as well.

  25. #50
    SitePoint Evangelist
    Join Date
    Feb 2009
    Posts
    412
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by BPartch View Post
    You're asking how to limit the number of posts that appear on an archive page? If so, this is under settings > reading > number of posts to display or something similar. This will also limit the number of posts on the main posts page as well.
    ok for example, let's say i pull an archive and get this page template working and it has some limit to the number of links it will display correct? if so then let's say for example the limit is at 50 and there are 100 links so it will break up onto two pages but how do i display the link to page two in that format?


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •