Skocz do zawartości
"Idzie nowe..." - o zmianach i nie tylko ×
Przeniesienie zakupów z IPS Marketplace / Moving bought items from IPS Marketplace ×

[IPS Marketplace] IPS Pages Category Images


Rekomendowane odpowiedzi

IPS Pages Category Images

Add an image to every IPS Pages database category for use in your templates!

Any settings?
Nope. Just install and go. When editing/creating a category in an IPS Pages database this plugin appends a new tab where you can upload an image. That's it.

And how do I use this?
Images are stored wherever you have assigned attachments to be stored and you can access the image anywhere the $category variable is available to you in Pages templates.

$category->pcimage = The local url to the stored image. You will rarely use this by itself as it will return "uploads/monthly_07/thisismyimagename_34erjfhrufhdheh.jpg" or something along those lines.

{file="$category->pcimage"} = The COMPLETE url to the stored image. "https://myawesomesite.com/uploads/monthly_07/thisismyimagename_34erjfhrufhdheh.jpg". Just sticking this in a template will output that as a line of text.

<img src='{file="$category->pcimage"}'> = The image will be displayed in your template at this location at full size.

You get the idea. From here you can format the image with css, use it as a background element, and so on. 

Why am I using this again?
Give every category its own image. Format it like an icon and stick it next to the category title in your templates. You could create a large section background for your categories using this image. And so on...

Why $category->pcimage and not just $category->image?
If IPS ever adds something like this to Pages database categories themselves I predict with 99.999% certainty they would use the word "image". I added the "pc" in front to hedge against that potential future conflict.

What happens if I disable this plugin?
Everything will continue to work, you just won't be able to add an image to Pages database categories until you re-enable it. You are just disabling the category edit/create category image tab when you disable this; that's all.

And if I uninstall this?
You will be warned that you will lose all of you uploaded images and then it will wipe all that stuff out. Consider that you will be editing your Pages templates to add calls to these images too. You'll need to edit your templates to remove those calls after you uninstall this.

Cost
$5 forever and ever and ever...  There is a yearly renew attached but that's just the tip jar - ignore the renew if you like or let it ride and buy me a beer every year! No yelling if you forget to cancel the renew invoice and you do buy me that beer; I promise to enjoy it though.

Terms/License
One buy, one site. Feel free to use on all your test sites if you have any. No uploading to warez/pirate sites which really should go without saying and yet here we are...

This file was sponsored by @Charl - Say hey to the man!


Thank You!

View the full article

Odnośnik do komentarza
Udostępnij na innych stronach

Jeśli chcesz dodać odpowiedź, zaloguj się lub zarejestruj nowe konto

Jedynie zarejestrowani użytkownicy mogą komentować zawartość tej strony.

Zarejestruj nowe konto

Załóż nowe konto. To bardzo proste!

Zarejestruj się

Zaloguj się

Posiadasz już konto? Zaloguj się poniżej.

Zaloguj się
  • Ostatnio przeglądający   0 użytkowników

    • Brak zarejestrowanych użytkowników przeglądających tę stronę.
×
×
  • Dodaj nową pozycję...

Powiadomienie o plikach cookie

Umieściliśmy na Twoim urządzeniu pliki cookie, aby pomóc Ci usprawnić przeglądanie strony. Możesz dostosować ustawienia plików cookie, w przeciwnym wypadku zakładamy, że wyrażasz na to zgodę.