{exp:channel:entries channel="events" orderby="start_date" limit="5"}
{title}
{/exp:channel:entries}
...how would I amend this to achieve showing the 5 next events in the coming week
Thanks
]]>
I’m not clear on how to implement site navigation. I’ve chunked the site up into templates including a navbar template. when I put <a > tags into the navbar template, how do I set it up to load the correct page content when the link is clicked?
What’s the most basic, simple method of doing this easily?
Cheers
Si
]]>I’m thinking this should be pretty simple and I’ve missed something, but the relationship field just isn’t accepting a conditional… bug?
Here is an example of what I’m trying to achive:
{if child_pages}
<div>
<ul>
{child_pages}
<li><a href="{path=">{child_pages:_title}</a></li>
{/child_pages}
</ul>
</div>
{/if}
Basically I am unable to remove the div and ul if there are no “child_pages” resulting in an un-semantic empty div and ul
Any suggestions?
Cheers
[edit]
Ignore the anchor in my example for some reason it keeps being changed from what I actually have in there when I try to edit it.
How does that work with the {exp:channel:entries} tag?
Thanks!
]]>Get “Message: unserialize(): Error at offset 0 of 12 bytes” during the update, see my post here http://ellislab.com/forums/viewthread/235575/
I need to Export some data out - flatten the data and import back in the data I need to keep.
These data tables are from 1.6.8
exp_member_data
exp_member_homepage
exp_members
Each have 102,021
What other tables do I need to clear to remove all associations?
I don’t think I can update until I clean out the spam.
]]>
$selected_items_count = $_POST['gadget'];
if ( count( $selected_items_count) >= 1 && count( $selected_items_count) <= 4 ) {
....
}
But then again, I’m using CodeIgniter
I want to use the form validation library to accomplish this. I tried creating a callback function but each element in the $_POST[“gadget”] is getting passed to it separately and not as the array itself. Can someone kindly help me out !
Thanks a lot in advance.
]]>We have channel that we allow guests to post to via Safecracker - all works fine. However it would appear that every so often the permissions to post to the channel get reset to “NO” via the CMS, though we have not been anywhere near these options in the admin panel.
It looks like a wee bug in EE and I was wondering if anyone else had ever experienced this and if so - are there any fixes please?
Many thanks
Jonathan
]]>I thought about switching the great than sign in the if statement when comparing the two times but with those two I didn’t think it would make sense.
$current_time = now();
$current_gmt_human_format = unix_to_human($current_time, TRUE, 'us');
/* Get user data from post username value */
$user_data = $this->users_model->get_by('username', $post_username);
if (count($user_data) > 0)
{
/* User was found in database */
if ($user_data->lock_date !== '0000-00-00 00:00:00')
{
/* User is locked out */
/* How long the user must wait to login */
$wait_time = 60 * 15;
/* Time user is able to login */
$time_to_login = human_to_unix($user_data->lock_date) + $wait_time;
//echo 'current time is...' . $current_time;
//echo '<br>';
//echo 'time to login is...' . $time_to_login;
//die();
if ($current_time < $time_to_login)
{
}
}
}
As per the request here is the data I have.
current readable format is...2013-05-23 08:03:44 PM
current time is...1369353824
user lock out...1369310405
wait time is...900
time to login is...1369311305
]]>
The Va_custom_member Plugin has three main functions. First, it outputs the contents of one custom member data field—useful for including inside a weblog:entries tag, for instance. Or a forum template….
Second, It also allows for dynamically selecting categories based on the contents of member custom data.
Third, it will translate a category name into a category id. Useful for weblog entry tags.
To install: expand the download and drop the file in your system/plugin folder. It’s now available for use. You can read the instructions in your admin page/ utilities page and then the plugin manager.
Full instructions are in the plugin page once installed.
Here’s a summary of what this plugin does:
1) First usage
This plugin allows the contents of a member’s custom data field to be output. In a single tag, not a tag pair. This can be anywhere, in any template. That’s right, you can use this in a forum template, too. Ever wish you could output each poster’s custom field on their post? You can now. I’ve included explicit instructions on how to do that as well.
2)
This plugin allows you to dynamically select a category based on an equivalent custom member field. In other words, each member’s custom data can control what category your weblog entries field runs.
Consider the value of a category. It’s useful, for sure… but how can you tie a category to each member dynamically? With this function, you can, say, get a list of teams as a category. For instance, lets say you have a weblog that has team news for every NFL team. You can create a category, with each NFL team as a separate category. You can ALSO create the exact same list for a drop-down in the member profile field, as a custom member data field. Members can then select the team they are a fan of. With this function, you can then in your weblog entries tag dynamically assign the category you want displayed based on what team the member chose in their custom member field.
Example: Your site has news about professional American football. You’ve set up a category group with the names of each professional football team as it’s own category. You also set up a custom member field that is a drop down list; each line of the list is the same name as the category you’ve chosen. One member of your site is a fan of the football team Chicago Bears. They have selected the Bears in their member custom profile data. In your weblog, you have a category for each team name. You have a story for the Bears. With this function, when your member that’s a Bears fan visits this template with this weblog entries, this plugin will generate the category that corresponds to the Bears, based on the members custom data. The category is only the Bears, and the weblog tag only shows the Bears category. The next member is a New York Giants fan, and THEY have a category that corresponds to the New York Giants.
This opens up lots of possibilities, clearly.
3)
Third usage: Category name to category ID translation (thanks, Lisa, for the suggestion!)
Your weblog entries tags have to have a category ID to govern category displays, right? Which sucks if you are using category URL names, but on one page you want this to be different. This plugin also will translate your category name into a category ID for the weblog entries tag. It also means you can use any segment of your URL as the category name… or even if the category name feature is turned off, you can still use it sporadically with this plugin. Can be useful sometimes.
I hope this plugin is useful—I think it opens up a powerful set of possibilities for category and member data synchronization, plus forum customization. It’s my first plugin, so I hope I’ve done things right… and let me know, please, of the no doubt numerous errors there are in here. Thanks!
Edit: Added a EE 2 version. Completely untested for the moment, it will no doubt be updated.
And it’s updated some
anyhow i am using xampp win 8 with no mail server
supposedly you can get someone to sign up to your site and get gmail to send from that account,
well i cant get it to work, i have been here from 9pm till now 4.30am trying to figure it out, i have found alot of answers from this site and others, and still failed, i have a test page wich just send a hello message and it works i get email from Gmail site account to the hotmail one, but when i try to sign up to my site i get error,
any help would be good, i dont want to double post so once i get a reply i will post the codes (if this site lets me this time.)
error message
The following SMTP error was encountered: 10061 No connection could be made because the target machine actively refused it.
New Error
The following SMTP error was encountered: 0 php_network_getaddresses: getaddrinfo failed: No such host is known.
Unable to send data: AUTH LOGIN
Failed to send AUTH LOGIN command. Error:
Unable to send data: MAIL FROM:
Unable to send data: AUTH LOGIN
Failed to send AUTH LOGIN command. Error:
Unable to send data: MAIL FROM:
as i said when doing it on same port and SMTP setting but with a .php file wich once clicked send out an email from gmail to my hotmail account, that works fine
]]>