Host Unlimited Web Sites for Only $10 per Month! استضافة مواقع غير محدود فقط 10 دولار شهريا!
Powered by MaxBlogPress مدعوم من MaxBlogPress

وورد هاك # 19 : التقطيع علامة صفحات | JTPRATT 'sالتدوين الأخطاء
JTPratt 'sأخطاء المدونات





Home المنزل » Wordpress Hack #19: Hacking Tag Pages »وورد هاك # 19 : التقطيع علامة صفحات



Posted in: نشر في :

بلوق بين الإعداد فئة الصورةالمدونات فئة الصورةالمدونات بين أخطاء فئة الصورةووردبرس] فئة الصورةووردبرس] سيو بين فئة الصورة
395 views آراء 395


Please note: This page was originally written in English. الرجاء ملاحظة : هذه الصفحة كان أصلا مكتوب باللغة الانكليزية.

The original post can be viewed الأصلي بعد ويمكن النظر إلى here هنا .

Please note: This page was originally written in English.

The text has been translated using an online service such as Google or Babelfish.

The original post can be viewed here.


This unique Wordpress hack will allow you to index tag pages you create without having to create template files for each and every one. وورد هذا الإختراق فريدة من نوعها تسمح لك بطاقة الرقم القياسي لخلق الصفحات دون الحاجة إلى خلق نموذج للملفات كل واحد.

This post is part of هذه الوظيفة هي جزء من 30 Wordpress hacks in 30 days 30 المأجورون وورد في 30 يوما .

Back in في العودة Wordpress Hack #15: Hacking Wordpress Tags وورد هاك # 15 : التقطيع وورد العلامات I described how to add “tag support” to your Wordpress theme files, and how to add a “tag cloud” like the one I use on this blog in the bottom of the left sidebar. ووصف كيف لي أن أضيف "بطاقة دعم" الى حسابك في موضوع ملفات وورد ، وكيفية لإضافة "بطاقة سحابة" أنا مثل واحد على استخدام هذا بلوق في أسفل الشريط الجانبي الأيسر. When you “tag” pages you are actually creating additional pages in your blog - that can get indexed by search engines. عندما "العلامة" صفحات انك فعلا إنشاء صفحات إضافية في حسابك بلوق -- التي يمكن أن الحصول فهرسة بواسطة محركات البحث.

For example, let’s say that I create a new post about an iPod. فعلى سبيل المثال ، دعونا نقول أن الأول خلق وظيفة جديدة عن أجهزة أي بود. I put the post in the “gadget” category, and tag it “iPod” and “mp3 player”. أنا وضعت في ما بعد "الأداة" فئة ، وبطاقة "آي بود" و "mp3 لاعب". Within the Wordpress paradigm many things happen… ضمن نموذج وورد كثير من الأمور...

  1. A new post page is created based on your single.php theme file using the post title as permalink ألف وظيفة جديدة لإنشاء صفحة على أساس single.php موضوع الملف الخاص بك باستخدام وظيفة لقبه بطلا لpermalink
  2. The post is added to the top of your blog home (usually your index.php home, unless you changed it - like I did) بعد يضاف إلى الأعلى من الصفحة الرئيسية الخاصة بك بلوق (عادة الخاص بك index.php المنزل ، ما لم تغير لكم أنه -- مثلما فعلت)
  3. The post is added to the appropriate archive pages for day, month, year, etc. بعد يضاف إلى أرشيف صفحات لمناسبة اليوم ، الشهر ، السنة ، الخ.
  4. The post is added to all “category” pages you assigned it to بعد يضاف إلى كل "فئة" الصفحات المخصصة لها
  5. The post is added to all “tag” pages you added it to بعد يضاف إلى كل "العلامة" الصفحات التي أضافتها إلى

If you read إذا كنت تقرأ Wordpress Hack #18: Wordpress Template Files وورد هاك # 18 : ملفات وورد قالب , you already know that you can create custom “tag” and “category” pages, so when the old google crawler comes a-knockin’ it will find original content and not penalize your blog in search rankings. ، نعلم أن لديك بالفعل يمكنك إنشاء عرف "العلامة" و "فئة" صفحة ، حتى عندما يبلغ من العمر جوجل الزحافة ويأتي بين knockin 'أنها سوف تجد المحتوى الأصلي وليس معاقبة البحث الخاصة بك بلوق في الترتيب. The problem normally is - if you’re a prolific blogger, you (like many of us) may have a few dozen categories, and hundreds (if not thousands) of tag pages. المشكلة هي في العادة -- إذا كنت خصيب مدون ، لكم (مثل كثيرين منا) قد تكون بضع عشرات من الفئات ، ومئات (إن لم يكن الآلاف) من العلامة صفحة.

When you categorize a post, you can find it within your blog at: عندما كنت تصنيف وظيفة ، يمكنك العثور عليه داخل حسابك في بلوق :
www.site.com/category/cat-name www.site.com / فئة / القط اسم

When you tag a post you can find it within your blog at: عندما كنت وظيفة العلامة يمكنك العثور عليه داخل حسابك في بلوق :
www.site.com/tag/tag-name www.site.com / علامة / بين اسم العلامة

To create a custom page for any category or tag page, all you have to do is use your index.php or single.php to create a new Wordpress theme file. لإنشاء صفحات مخصصة لأية فئة أو علامة صفحة ، كل ما عليك القيام به هو استخدام الخاص بك index.php single.php أو لخلق جديد موضوع ملف وورد. Open either index.php or single.php in a text editor and “save as” either: إما مفتوحة أو index.php single.php في محرر نصوص و"إنقاذ" إما :

category-id.php (for category pages) الفئة - id.php (لفئة صفحة)
or أو
tag-slug.php (for tag pages) العلامة - slug.php (للعلامة صفحة)

This means if my “gadget” category was “17″ then my theme file for it would be “category-18.php”. وهذا يعني لو كانت لغتي "الأداة" فئة "17" ثم بلدي موضوع ملف لأنه سيكون من "الفئة - 18.php". If my tag was “mp3 player”, then my theme file for it would be “tag-mp3-player.php”. وإذا كان لي علامة "mp3 لاعب" ، ثم بلدي موضوع ملف لانها ستكون "العلامة - mp3 - player.php". View my رأي بلدي Wordpress Template Files قالب وورد ملفات hack page for pics and a better description. الإختراق صفحة للبلدان جزر المحيط الهادئ وأفضل وصف.

So - What “I” did was create category theme files for every category I had. حتى -- ما هي "أنا" لم كان خلق فئة موضوع ملفات لكان كل من الفئة الأولى. THEN, I created a single “tag.php” file that would display for every tag page I have. وبعد ذلك ، أنا خلق واحد "tag.php" التي من شأنها أن ملف لعرض كل صفحة علامة لدي. What I didn’t mention up until now was that if you create a “category.php” and “tag.php” file and put them in your theme directory that these will be used for ANY category or tag pages that don’t already have one for that slug or ID. ما لم اذكر حتى الآن هو أن خلق لكم لو "category.php" و "tag.php" ملف ووضعها في الموضوع الخاص بك دليل على أن هذه سوف تستخدم لأية فئة أو بطاقة الصفحات التي لا بالفعل وقد لأن رصاصة واحدة أو هوية.

Every blog is of course a different topic (or niche), but this is what I did for tag pages on one blog I own. كل بلوق هو بالطبع موضوع آخر (أو المتخصصة) ، ولكن هذا هو ما فعلته لعلامة واحدة على صفحة بلوق أملك. I used the tag title to create a different description lead-in sentence to get each tag page listed in the search engines. أنا استخدم بطاقة عنوان لخلق مختلف وصف الرائدة في الجملة للحصول على كل صفحة علامة المدرجة في محركات البحث. Right before “the loop” I placed this bit of code to do that: الحق قبل "حلقة" أنا وضعت قليلا من هذا القانون للقيام بذلك :

 <p><?php single_tag_title('This page is about '); ?>! My blog is about geeky tech stuff, technology, Linux, gadgets, web tools, and more! <?php single_tag_title('If you like '); ?>, the posts below should be right up your alley!! 

That code gets the “tag_title” and uses it like this (for the example “mp3 player”): أن يحصل على رمز "tag_title" وأنه يستخدم مثل هذا (للاطلاع على مثال "مشغل MP3") :

“This page is about MP3 Players! "هذه الصفحة عن مشغلات MP3! My blog is about geeky tech stuff, technology, Linux, gadgets, web tools, and more! بلدي هو بلوق عن الاشياء geeky التكنولوجيا ، والتكنولوجيا ، لينكس ، الأدوات ، وأدوات الإنترنت ، وأكثر! If you like MP3 Players, the posts below should be right up your alley!!” إذا كنت مثل مشغلات MP3 ، وظائف أدناه ينبغي أن يكون الحق حتى زقاق الخاص بك!! "

I did this a month ago on one of my blogs, and all the tag pages are indexing nicely! فعلت هذا قبل شهر واحد على واحد من بلدي بلوق ، وكل بطاقة فهرسة الصفحات لطيف! I’m sure you could hack this up even further - but this simple little solution fixed my tag page indexing problem quickly. أنا متأكد من أنك يمكن أن الإختراق هذا حتى أكثر من ذلك -- لكن هذا الحل بسيط الثابتة بلادي صفحة بطاقة الفهرسة المشكلة بسرعة.


Tags: العلامات : , ، , ، , ، , ،

11 Responses to “Wordpress Hack #19: Hacking Tag Pages” 11 الردود على "وورد هاك # 19 : التقطيع علامة صفحات"

  1. Erika اريكا Has the following to say... وقد التالي ليقول...

    Yikes… I think you might’ve missed a code tag in your post? Yikes... اعتقد انكم قد لقد غاب عن مدونة العلامة الخاصة بك في ما بعد؟

    Erikas last blog post.. Erikas الماضي بعد انتهاء بلوق.. Miami Web Design تم تصميم الموقع من ميامي

  2. admin الادارية Has the following to say... وقد التالي ليقول...

    fixed now - thanks! الثابت الآن -- بفضل! =)]

  3. Anthonyq Anthonyq Has the following to say... وقد التالي ليقول...

    Another great tip which i’m implementing right now! عظيم آخر الحافة التي أنا الآن تنفيذ الحق!

    Question thou : how do you trunticate your listings in the Tag Page order to avoid duplicate content? .. والسؤال : كيف trunticate القوائم الخاصة بك في علامة الصفحة لتجنب ازدواجية محتوى؟

  4. Mark - The Niche Store Builder مارك -- مكانة تخزين البناء Has the following to say... وقد التالي ليقول...

    Hey man - Glad to see your back!! يا رجل -- سعيد لرؤية الاحتياطية الخاصة بك!! Either I missed a bunch of posts, or you took a vacation! إما فاتني حفنة من الوظائف ، أو هل أخذت اجازة!

    Mark مارك

    Mark - The Niche Store Builders last blog post.. مارك -- مكانة المتجر بناة الماضي بعد انتهاء بلوق.. Creating your Own little WordPress Playground خلق بنفسك قليلا ملعب ووردبرس]

  5. jj-momscashblog ي ي - momscashblog Has the following to say... وقد التالي ليقول...

    Hi JT, First time here and I’ve enjoyed your posts, full of lots of info. مرحبا ج ت ، لأول مرة هنا ولقد استمتعت رسائلك ، الكامل من الكثير من المعلومات. will have to come back and read a couple of others that I thought looked interesting. وسيكون ليعود بعد فترة وقرأ اثنين آخرين اعتقدت أن يتطلع للاهتمام. thanks so much . شكرا جزيلا. I also wanted to let you know your Entrecard will be on my blog tomorrow, so many thanks for that. وأردت أيضا أن أخبركم Entrecard الخاص بك سيكون على بلدي بلوق غدا ، حتى أن العديد من الشكر. =

  6. admin الادارية Has the following to say... وقد التالي ليقول...

    @jj-momscashblog - thanks for the kind words, glad to have you here! @ ي ي - momscashblog -- الشكر للكلمات الرقيقة ، لسعيد هل هنا! =)]

  7. admin الادارية Has the following to say... وقد التالي ليقول...

    @Mark - thanks for the comment! @ مارك -- الشكر للتعليق! No - I didn’t post at all last week and only once the week before (too busy!). لا -- لم أكن بعد في جميع الاسبوع الماضي ومرة واحدة فقط في الأسبوع السابق (مشغول جدا!).

  8. admin الادارية Has the following to say... وقد التالي ليقول...

    @Anthonyq - I don’t truncate the listings on my tag page (other than maybe excerpt) to avoid duplicate content, it’s just not any issue (in google) anymore. @ Anthonyq -- أنا لا بتر القوائم علامة على بلدي صفحة (عدا ربما مقتطفات) لتفادي تكرار مضمون ، انها مجرد مسألة لا أي (في جوجل) بعد الآن.

  9. Anthonyq Anthonyq Has the following to say... وقد التالي ليقول...

    Ah ok. آه طيب. I was looking on your blog here, i noticed that the listings were summaries. كنت أبحث عن بلوق الخاص بك هنا ، لاحظت أن قوائم ملخصات. Wondering how you do that? ويتساءل كيف نفعل ذلك؟

  10. Dennis Edell دنيس Edell Has the following to say... وقد التالي ليقول...

    Love these posts. الحب هذه الوظائف. I’m saving them all for when I may be confident enough to hack without destroying. انا كل لانقاذهم عندما الأول قد يكون واثقا بما يكفي الإختراق دون تدمير. :-)

    Dennis Edells last blog post.. دنيس Edells الماضي بعد انتهاء بلوق.. Grab Your Offline Marketing Tools Here Too! انتزاع الخاص بك غير متصل أدوات التسويق وهنا أيضا!

  11. admin الادارية Has the following to say... وقد التالي ليقول...

    @Dennis - I would read @ دنيس -- أود أن تقرأ showing only a post excerpt in Wordpress لم يظهر فيه سوى وظيفة وورد في مقتطفات .

Question or Comment?? السؤال أو التعليق؟؟ Spill it Now... انسكاب الآن...

القفز للفرح أكثر من التعليقات!

We Reward Comments! نحن مكافأة تعليقات!


We dofollow links, and get your latest blog post as a byline under every new comment from the "CommentLuv" plugin! نحن dofollow الروابط ، وإحصل على أحدث ما بعد بلوق بوصفها الخط الثانوي تحت كل تعليق من جديدا "CommentLuv" البرنامج المساعد! Top commenters for every month are listed on every page of this site in a sidebar widget linked back to your URL! أعلى commenters كل شهر لترد على كل صفحة من هذا الموقع في الشريط الجانبي القطعة مرتبطة العودة إلى وصلتك! We would like to reward you for becoming part of our community! ونود أن مكافأة لك لتصبح جزءا من مجتمعنا! Your comment is valuable not only to us, but also all the other readers of this blog! تعليقك هو قيمة ليس فقط لنا ، بل أيضا سائر قراء هذا بلوق!


Click to add smilies to your post! انقر لإضافة الابتسامات إلى حسابك في ما بعد! == []^ = (= ((= (|=) ص= | 8= 0=) ~= 00= (= ؛ ؛=)]= ؛ ؛ ؛