Hot answers tagged

13

In most cases, using relative paths are fine, though you won't see any performance gain there (replacing global variables like {site_url} is the tiniest of tasks). But in the cases where you do want a full URL generated, {site_url} is not the best way to do it - instead, you should use {path=""}, {permalink=""}, {title_permalink=""}, etc. This way you'll ...


11

There are a couple of ways to create plugins which return entry IDs like that. The first, and most obvious, is for your plugin to return a pipe-separated list of entries, which is then passed to a channel entries tag. In your plugin file: $tag_vars = array(array('search_entry_ids' => '4|6|12|19')); $this->return_data = $this->EE->TMPL->...


11

If you enable the Output Profiler you'll see the profiler at the very bottom of the page. Look around for this: If you click the show link you'll see all of the queries required to build your page along with the file, line number, class, and method that ran that query: You might still need to do a bit of hunting because a query could be created in one ...


5

I would like to point out that your first example is not a relative path - it's an absolute path with a variable domain. This crucial difference explains why the full path in your second example is the preferred form. If you have a page at example.com/foo.html, and a page at example.com/bar/baz.html, there's a few ways to link to the second page from the ...


5

In addition to the fine answer by Wes I'd add that most likely you don't need to "find a better solution" you just need to use the disable parameter in your exp:channel:entries tags. A couple of those JOINs will be eliminated with this simple fix.


5

You can add disable_form="yes" to the {exp:store:product} tag to disable the creation of the form. (Docs.)


4

You can wrap your code in [code]{ee_tag_here}[/code] and that should output <code>{ee_tag_here}</code> into your template.


4

The {reverse_related_entries} does support only 6 parameters of weblog, status, sort, orderby, offset, limit. So "show_expired" parameter will not work here. In that case I always prefer to use Playa but never tried with EE v1.6+. I think, you are populating a single weblog entry and would like to show all the parents weblogs with {reverse_related_entries}...


4

http://ee1docs.com/quick_reference.html and you can see top right button "Download EE1 Docs" at http://ellislab.com/expressionengine/user-guide/


4

Yes this is possible. It took me a while to find some documentation when I first tried to do it within a plugin. You need to look at the docs for the template class instead of the plugin API. Specifically the section for variable pairs. You need to create a multidimensional array that contains the different rows for your variable pair. Here's some relevant ...


4

Your first 2 tokens are both month tokens. Essentially you're outputting "February February 2013". Try %F %j %Y or %F %d %Y instead. (See PHP date formatting tokens.)


4

Ok - found a fix for this. This simple condition {if shipping_same_as_billing} ALWAYS SHOWS AS TRUE! <p><strong>Same as Billing Details</strong></p> {if:else} No longer works, but altering the condition to be more specific does. {if shipping_same_as_billing == 1} ...


4

By default, EE is support calculations in conditions only. For other cases you can use MX Calc {exp:channel:entries channel='links' orderby='link_order' sort='asc' dynamic='no' category='12' parse="inward"} <div class="item" id="pane-{exp:mx_calc expression='{count}+15'}" style="display: none;"> <!-- stuff here --> </div> {/exp:...


4

The best thing to do is have Tag convert to lowercase. There is a setting for that under preferences.


3

Is it an EE1 site? If so, go to Extensions, then Fieldframe's settings and check the path.


3

Go to this field via Admin > Channel Administration > Channel Fields > Group > Field and switch the formatting back to XHTML confirm and then back again to none. When switching EE should show a checkbox before confirming asking if you want existing fields to be reformatted. Check this. Alternatively keep as XHTML in EE and use a plugin to alter the rendered ...


3

For showing categories you can use "GWCode Categories" plugin which is having "orderby" parameter with "random" value. Like: {exp:gwcode_categories orderby="random"} {category_name} {/exp:gwcode_categories}


3

Speed wise I would go for the relative paths (less DNS lookups) Also for java and css (minified) I would use relative paths. (major speed increase) So basically if you are running one website with EE, I would go for relative paths. Speed increase is not due to the fact that EE needs to enter the domain in every {site_url} tag. it's due to the DNS lookups/...


3

I'm guessing your comment form is nested inside a Channel Entries tag? Try using {logged_in_email} instead.


3

There is only one correct syntax style: {companies_type:label}. If it's not working you might have changed your options after saving an entry. So the stored value is not matching any options anymore and thus resulting an empty value for {companies_type:label} and {companies_type}.


3

It's a BBCode problem: http://ellislab.com/expressionengine/user-guide/general/bbcode.html Pretty sure the issue here is the first [i] only, all subsequent [ii], [iii] should not be replaced as bbcode by EE. A dirty but effective method would be to change the very first instance of [i] to [&#105;] which is the html entity for the letter i. I tried a ...


3

Layouts are a bit hard to get your brain around to begin with. There are two things you need to know, and I think you'll be on top of it. Layout templates work by letting you drop the content from one template within another. The places that the content appears are defined by the position of the {layout:variable} tags that you put within the layout ...


2

Assuming you have more than one page to your checkout process, the easiest way to do this is simply to submit a hidden field on the first page of your checkout which checks the register_member field. For example, simply add this to the first page of your checkout form: <input type="hidden" name="register_member" value="1" /> Now, by the time the ...


2

You'll need to wrap your Wygwam field in the Allow EE Code plugin tags within your template: {exp:allow_eecode embed="y"} {your_wygwam_field} {/exp:allow_eecode}


2

Found the solution. The tag {order_email} works in the email templates.


2

I think you're on the right track with switchee, and something like the following should work: {your_relationship_field} {exp:switchee variable="{your_relationship_field:channel}" parse="inward"} {case value="news"} <a href="{url_title_path='news/entry'}">{your_relationship_field:title}</a> {/case} {case ...


2

uri_page="{last_segment}" is not a valid parameter for channel entries. You're looking for url_title I imagine :) {exp:channel:entries url_title="{last_segment}"} {exp:stash:set_list name="related_articles"} {related_articles} {stash:rel_title}{related_articles:title}{/stash:rel_title} {stash:rel_excerpt}{related_articles:excerpt}{/stash:...


2

If you're able to compile all of your data into something like a spreadsheet, you may be able to use one of the import add-ons like Solspace Importer, Data Grab, or Data Import. I've been using Solspace Importer for something similar to what you want to do, and it works well--and accomplishes a big chunk of the batch processing that I need. However, in my ...


2

EECMS just saves the IP of who edited an entry, not his or her member_id. You can try the Audit add-ons: Audit Pro, which lets you archive logged data, set custom email notifications and search log entries; Audit Tags, which lets you output Audit’s logged data in your templates. The add-on can be found on github as well.


2

Allows ExpressionEngine code to be used in entries and then parsed in the template. Currently, you cannot put EE tags into an entry/post and have them rendered in the template. Instead, the code itself will just display, unprocessed. This plugin makes it so any EE tags in an entry will actually be parsed and have results outputted. Allow EE Code by ...


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