Numbering Your Entries
-
I’m trying to find a way to list my home page entries without using the OL tag. I first saw this accomplished here: https://blog.jalenack.com/
His latest post has a 1. and so on. Any ideas as to what I can do to accomplish this?
thanks.
-
Whooami – thanks. But in the end, I didn’t really get any help from you.
no you didnt. other than a confirmation that’s its doable. PHP is a wonderful language.
PHP is a great language. One that I don’t know to extent. I really hate to bother you, but could you provide a reference, or somewhere that I can learn a approach?
It would be helpful and appreciated.
Edit: Scratch that. It will only work for the first page. The Jalenack page is counting some other way probably using the_ID() to keep the count.
– – – – – – – –
Chad try this:
In your theme locate the
<a href= ... <?php the_title(); ?>
In the default theme that line starts off with
<h2><a href="<?php the_pemalink() ?>
Right after the <h2> insert
<?php echo $p_count+1 . ". "; ?>
Right before the line that reads
<?php endwhile; ?>
Insert above that line this
<?php $p_count = $p_count + 1; ?>
This will print a 1. , 2. , 3. , etc. inside of the h2 but before the link to the post.
Hope that helps.
Hey, thanks friend. Actually, all I need is to count on the first page, so this just might do it. I’ll let you know if it works, and show what I was doing.
Alright, you can see what I did, by going to this site, and looking at the box of “Today’s Posts”.
The client wanted “Today’s Posts” to show the latest 10 posts, with the first 5 on the left column, etc.
But this was tuff, without being able to add a individual class to each of those titles. I used the code you gave me, added the word “today” in front of the post number, to give me today1, today2 etc.
Then I was able to apply some ALA CSS Swag list tricks, and finally achieve the goal.
So, thanks alot for your help, jdembowski.
And as for whaoomi… maybe you should stick to the site critique forum. Cos if you’re gonna come to the “how-to and help” forum, and patronize folks asking for help, the place is better off without you.
It’s a good thing the folks who made WordPress don’t run in your crowd.
Er did I just hear the word *client* ?
You would hear that word if you really want that kind of client.
yes you did root — hence my response. ??
Chad,
I wasnt being patronizing in the least. I am merely hesitant to assist those that are doing paid gigs.
root – whats the beef?
ccoupe – i don’t follow.
whooami – “neener neener neener” isn’t patronizing? and you didn’t even know it was a paid gig, until it was all said and done.
I don’t see what the beef is as far as getting paid for the many hours I spend building a client a custom WP theme.
I posted that to MY site — did it ever occur to you that other ppl actually read that as well ??
Had I wanted to patronize YOU, I would have done it here — and it wouldnt have been the first time I would have been called on it.
As for knowing — I didnt “KNOW” for a fact, no. That said, I did see your other post regarding the blog for that military thing. Your profile indicates you are clearly a designer. etc.. etc..etc..
I’m not fricken blind.
In other words, I “knew”.
Lastly, no one takes issue with someone making money. Thats the pat reply “why cant I make money..” etc.. YOU CAN.
What I dont help with is ppl that want to make money by using someone else’s brain power.
Look at it like this:
You are doing a kitchen remodeling. You are the cabinet builder. In the course of doing the cabinets, you realize that there is plumbing work to be done. Do YOU really think a plumber is going to tell you how to do plumbing??? NO! He’s going to say — hey, Im a plumber, Ill help but I charge.
You suggest that you are entitled to make money off your talents — and I accept that. I’ll also suggest that it goes the same for those of us here.
What possible benefit is there to me to give you code that you can use to make money? I help enough ppl on here, my ego doesnt suffer for lack of helping. I dont get a special avatar for posting.
There is NOTHING unreasonable about expecting that someone, as I said above, share the wealth, if they expect help with a paid job. Rather than make a big deal out it in this thread.. I tossed out my offer. You sluffed it off (Thats YOUR choice), I moved on.
THATS MY choice.
meh. and for the record — there are more than a handful of ppl on here that agree with that point of view.
I understand the analogy, and I have no beef sending out money. Now, had jdembowski hinted at tipping his/her paypal after providing me with the code, I would be completely fine sending them 35 bucks for their trouble. It’s no skin off my back, I pass it on to the client. I’m not a cheap skate. But now I guess that I need to state that I’m making money off your help, and then put that I’m willing to pay.
There are many web support forums, where members don’t mind sharing a bit of help to a pro web designer. This is the last place I expected it. The WP community has helped me learn alot over the past few years, and I’m not past sending out money.
On a side note – because I’ve been helped by people here, I have no problem helping other people on here, and not expecting money from it.
jdembowski – I am more than willing to pay you for you help. please let me know.
Chad – I have no issue with you. But you would be surprised (or maybe you wouldn’t) at the number of half assed designers who get paid work and dump the whole problem in stages – and often under different ids in this forum. As a rule of thumb if I was ever in the middle of a paid job and couldn’t manage it I would email my friends lest my client reads this forum as well:) If I needed help here I would fess up straight off the bat that it was paid. Then I would hope that someone would help and in turn I would acquire an obligation to help them if they got jammed up. Or I would offer to pay straight away.
Root – I completely understand and agree. My perspective was that if I can get some help on here, I don’t mind returning the favor to someone else who needs help on here.
I didn’t even consider that because money was involved, there are new rules.
I didn’t even consider that because money was involved, there are new rules.
There isn’t, as evidenced by the fact that you WERE eventually helped. I expressed MY point of view – nothing else, nothing more. You addressed me, I responded.
Thanks, but I dont need tips, all the same.
- The topic ‘Numbering Your Entries’ is closed to new replies.