We changed our privacy policy. Read more.

Hot answers tagged

3

The only sensible way to do this with a single channel entries loop is to use Stash and create one or more Stash lists within your loop. Then outside the entries loop use the Stash list to output the titles, followed by the contents. I think it would go something like: First create the Stash list variables (there are a couple of ways to do this) {exp:...


3

Your original code can't work because of parse order. Tag pairs are not parsed procedurally as you assume. Module tags are parsed from the outer layer inwards - like peeling an onion. Plugin tags (the low_replace tag in this instance) are parsed in the opposite direction (unless parse="inward"). In your code therefore the get_list (layer 2) occurs before ...


2

You could use Channel Files or Assets and have all of those documents attached to 1 single entry. Avoid using raw PHP in templates. If you must use PHP, extract it to a plugin.


2

The switch variable takes html as well. In case of your example: {switch='<ul class="sub">||'} <li>{title}</li> {switch='||</ul>'}


2

Low Alphabet is great and you will get excactly wat you want


2

Low Alphabet was created for this exact purpose.


1

Hrm, well that line in ext.rte.php in the 5.3.0 release is: var $docs_url = DOC_URL.'add-ons/rte/control_panel/index.html'; So based on that error, I would assume the DOC_URL constant is not yet defined, or isn't being type interpereted as a string. So try this: var $docs_url = ''; If the pages loads, this smells like it could be a bug; start by ...


1

Suspect it is because you are using different context settings between setting the list and getting it back again. You set the list using {entry_id} as the context. You retrieve the list using {item_entry_id} as the context. But you don't seem to be setting / saving the value {item_entry_id}. If you are basing this code on the examples on the lists page ...


1

I believe it's outputting the same thing over and over as you've only captured the last 'quote' – you are capturing inside the {exp:channel…} tag. So every time EE returns another entry, you are overwriting the last entry. Try instead: {exp:stash:set_list name="quotes" trim="yes' parse_tags="yes"} {exp:channel:entries channel="ffq" status="open"} ...


1

Friend-o, the DOM viewport is client side. http://detectmobilebrowsers.com Using these scripts you can detect the user-agent header. This still won't tell you the viewport size, just if someone is on mobile. To do exactly what you want, you'd have to write some JavaScript to watch the viewport size and then rebuild your channel entries loop with ajax. ...


1

Literally, you have a fine answer. There really is no other way to get the result you want except for how you're doing it. I double up on channel entry tags in templates all the time, especially when creating image sliders and the like (having to output an image and a caption in two different places). You may be concerned about efficiency: Sure, it's less ...


1

Sorry for the lack of clarity, I have figured this out and will detail it in case someone makes the same mistake I made. I have been working with EE to long to make this type of mistake, but figured detailing may help others. What this looked like on my end: The field type appear to install correctly, but when attempting to edit a page using this field ...


1

On your side nav {exp:channel: entries} tag you need to add dynamic="no" to tell EE to ignore the URL and list all entries. Keep your standard/main EE tags as is and u should be golden.


1

Use the dynamic="no" parameter on the channel entries tag for the menu, otherwise the channel entries tag will use the entry ID or url title from the URL to determine which entry to display.


1

Now that ExpressionEngine includes a modulus operator (as of 2.7.1), you can also use that instead of switch if you prefer. Here are a couple of examples that both accomplish the same result. Using modulus to conditionally output all opening and closing html tags: {exp:channel:entries channel="news"} {if count % 3 == 1} <ul class="sub">...


1

The issue is parse order. In your code {exp:stash:append_list name="resource"... Is three levels deep. Think layers of an onion. Whereas your {exp:gwcode_categories... is two levels deep but also requires the "resource" var which has not yet been parsed.


1

It turns out whitespace and placement of the closing categories tag was the issue. I moved the whole tag group onto 1 line in my template, and moved the , and closing categories tag outside of the closing </a> tag. Thanks Kevin and Nuno! I added a span so I could color the commas the same as the links. <ul> <li><p>Region: ...


1

Not tested, but this should work. We're checking to see if each fruit has parents, and if it doesn't, then we display it (and any child fruits). It would be helpful if the fieldtype had something like Playa's :total_parents and :total_children tags, but it doesn't (which is one of the many reasons I still use Playa). <ul> {if '{parents field="...


1

You could also achieve this using the Files module and File Entries tags. The Files module works much like Entries but you don't have to create them. Simply create an upload directory and put the files in there. Then sync the directory. To add a file to the directory you can use the File upload feature of the CP.


1

It can be possible with the PHP code within the template. Just create a template with "Allow PHP?" as "Yes" and use following code example: $library_dir = "/library/directory/path/"; $pdfs = glob($library_dir . "*.pdf"); foreach($pdfs as $pdf) { echo "<a href='[YOUR SITE URL]".$pdf."'>".$pdf."</a><br />"; } I hope, it would help you....


Only top voted, non community-wiki answers of a minimum length are eligible