1
sova
use smartys in theme
  • 2013/12/29 7:03

  • sova

  • Not too shy to talk

  • Posts: 149

  • Since: 2010/4/13


Why not make use of smartys in the themes?
For example:
we're calling The News Title in the themes
or
we're calling text (in module) in the themes
Without using the Modules block!
How do we do it?

it used In most other CMS. (WordPress, Joomla, Drupal and ...)

2
Bleekk
Re: use smartys in theme
  • 2013/12/29 13:24

  • Bleekk

  • Theme Designer

  • Posts: 940

  • Since: 2002/12/14


xoops is using smartys in the theme.
there are global smartys and you can use module smartys in the theme but only isnide the module

3
sova
Re: use smartys in theme
  • 2013/12/29 18:13

  • sova

  • Not too shy to talk

  • Posts: 149

  • Since: 2010/4/13


Quote:

Bleekk wrote:
xoops is using smartys in the theme.
there are global smartys and you can use module smartys in the theme but only isnide the module


How to use this smartys in Outside the module? (For example: in Home page theme)
calling The News Title in the Home page and Outside the News module.(Without using the Modules block!)

4
heyula
Re: use smartys in theme
  • 2013/12/29 20:49

  • heyula

  • Theme Designer

  • Posts: 590

  • Since: 2008/4/24


Hi @Sova

http://www.xuups.com/modules/publisher/item.php?itemid=10

5
sova
Re: use smartys in theme
  • 2013/12/30 8:37

  • sova

  • Not too shy to talk

  • Posts: 149

  • Since: 2010/4/13


thank you heyula

display = 'title' -> shows just title
display = 'none' -> renders the block but does not display it
options = 'enter|block|options' -> overwrites block default options
groups = 'enter|allowed|groups' -> overwrites block default group view permissions
cache = 3600 -> overwrite cache time(in seconds)

and for show just image or show just text?

It's also used
<{block id=31 groups="1|2|3" cache=20}>

But I mean was not this!
For example:
in Latest News Block:
we can calling just the news title, Not block Title.(or just news image) Without using the Modules block


6
sova
Re: use smartys in theme
  • 2014/1/1 19:02

  • sova

  • Not too shy to talk

  • Posts: 149

  • Since: 2010/4/13


Who can not help me?

7
Bleekk
Re: use smartys in theme
  • 2014/1/1 21:55

  • Bleekk

  • Theme Designer

  • Posts: 940

  • Since: 2002/12/14


there are no predefined smartys so you can only get article image of a certain article.
all you can do is use php in the theme and get all the stuff you want

8
sova
Re: use smartys in theme
  • 2014/1/2 6:55

  • sova

  • Not too shy to talk

  • Posts: 149

  • Since: 2010/4/13


This is what I've mentioned above, the most common use of the solar system
All systems go for the user's convenience
You can compare the position of these systems:
Wordpress vs. XOOPS
Joomla vs. XOOPS
PHP-Nuke vs. XOOPS (PHP-Nuke is a source of XOOPS)
12 years wasn'' t Time low?
XOOPS is still not as pervasive as in other systems.

What is our sin that we love XOOPS? And we do not know programming!

But I know someone does not answer my questions

===============
Excuse me to All.
I can not speak English well.
I get help from Google Translate.

9
Bleekk
Re: use smartys in theme
  • 2014/1/2 10:00

  • Bleekk

  • Theme Designer

  • Posts: 940

  • Since: 2002/12/14


sry but you have a special wish. I would really like to know the exact scenario where you need it.
you can not have one smarty for all modules. every module handles article images in different way.

in publisher you have a smarty for the article images. I am not sure of the name but let's say it is <article.image>.
take a unused publisher block and edit the template. delete everything except <article.image>
then take a unused block position and place it in the theme where you want to have the article image. activate the block in this block position

10
sova
Re: use smartys in theme
  • 2014/1/4 4:24

  • sova

  • Not too shy to talk

  • Posts: 149

  • Since: 2010/4/13


Thank you Dear Bleekk
But I just did exactly the same thing
The problem is here:
Sometimes it's necessary to put a block used in several places, But in different ways.
In such situations it is best to use the Smarty

How to use these in Theme?
<{$item.title}>
<{$item.text}>
<{$newitems.poster}>
<{$article.image}>

can I use this code in Theme?
<{foreach item=newitems modules=publisher}>
Or something similar

===============
Excuse me to All.
I can not speak English well.
I get help from Google Translate.

Login

Who's Online

176 user(s) are online (106 user(s) are browsing Support Forums)


Members: 0


Guests: 176


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Mar 31
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits