Smarty Forum Index Smarty
WARNING: All discussion is moving to https://reddit.com/r/smarty, please go there! This forum will be closing soon.

Search found 18 matches
Smarty Forum Index
Author Message
  Topic: Javascript onChange Not Responding in Smarty Template
ShamusMay

Replies: 6
Views: 8874

PostForum: General   Posted: Wed Oct 19, 2016 4:33 pm   Subject: Javascript onChange Not Responding in Smarty Template
Sorry to confuse you with the PHP tags... Let's move on from that with this code that has NO php tags...

It works fine in my HTML editor (outside of the Smarty template). The Javascript onChange su ...
  Topic: Javascript onChange Not Responding in Smarty Template
ShamusMay

Replies: 6
Views: 8874

PostForum: General   Posted: Wed Oct 19, 2016 4:16 pm   Subject: Javascript onChange Not Responding in Smarty Template
So this example with no PHP is not working... I just can;t get it to successfully submit. If I add a submit button it works, but I'm trying to make it work when the user picks a value from the dropdow ...
  Topic: Javascript onChange Not Responding in Smarty Template
ShamusMay

Replies: 6
Views: 8874

PostForum: General   Posted: Wed Oct 19, 2016 4:14 pm   Subject: Javascript onChange Not Responding in Smarty Template
Ignore the PHP part... I am just testing with that to pass data.

I'm more focused on the javascript and why it wont work on the client side.

Shouldn't the onChange="this.form.submit()" ...
  Topic: Javascript onChange Not Responding in Smarty Template
ShamusMay

Replies: 6
Views: 8874

PostForum: General   Posted: Wed Oct 19, 2016 3:57 pm   Subject: Javascript onChange Not Responding in Smarty Template
I have a simple sort dropdown form with a javascript onChange="this.form.submit()" value that is not working right within the Smarty template.

I have tested the form outside the Smarty e ...
  Topic: Limit Foreach Results within a Section Loop
ShamusMay

Replies: 3
Views: 6565

PostForum: General   Posted: Thu May 19, 2016 7:16 pm   Subject: Limit Foreach Results within a Section Loop
I guess it is just a grab everything function.

function getArticlesList() {
return
getSqlResult(
"select * from article order by article_topic_id, article_title&quo ...
  Topic: Limit Foreach Results within a Section Loop
ShamusMay

Replies: 3
Views: 6565

PostForum: General   Posted: Thu May 19, 2016 3:11 pm   Subject: Limit Foreach Results within a Section Loop
I have a piece of code for my article section that returns the Topic and all Articles associated to that topic. I want to limit the number of articles displayed to only 3 per topic. How can I achieve ...
  Topic: Count rows in array where 2 fields are gt or lt $smarty.now
ShamusMay

Replies: 4
Views: 5926

PostForum: General   Posted: Fri Jan 29, 2016 6:39 pm   Subject: Count rows in array where 2 fields are gt or lt $smarty.now
Done, thanks for the direction.
  Topic: Count rows in array where 2 fields are gt or lt $smarty.now
ShamusMay

Replies: 4
Views: 5926

PostForum: General   Posted: Fri Jan 29, 2016 3:23 pm   Subject: Count rows in array where 2 fields are gt or lt $smarty.now
Just thought I could use info already passed to smarty and use an if condition instead of another db call.
  Topic: Count rows in array where 2 fields are gt or lt $smarty.now
ShamusMay

Replies: 4
Views: 5926

PostForum: General   Posted: Fri Jan 29, 2016 2:51 pm   Subject: Count rows in array where 2 fields are gt or lt $smarty.now
I have an array of data with fields start_date and end_date

I want to get a count of only the rows where the start_date is gt $smarty.now and end_date is lt $smarty.now.

I know I can get the en ...
  Topic: Display Active SubCategories in Nav Tree
ShamusMay

Replies: 2
Views: 18054

PostForum: Smarty Development   Posted: Thu Jul 16, 2015 10:52 am   Subject: BUMP
Is there a way to call a specific row in the array instead of displaying the entire array loop?
  Topic: Display Active SubCategories in Nav Tree
ShamusMay

Replies: 2
Views: 18054

PostForum: Smarty Development   Posted: Tue Jul 14, 2015 7:13 pm   Subject: Display Active SubCategories in Nav Tree
I've got a navigation tree that displays all parent and subcategories. When on a subcategory page, I want to only display the active parent category and it's subcategories. Thank you for any help!

...
  Topic: Breadcrumb Help
ShamusMay

Replies: 2
Views: 7168

PostForum: General   Posted: Thu May 07, 2015 7:10 pm   Subject: Breadcrumb Help
OK...

I have the breadcrumb displaying the correct path, but the links are not clickable. I'm left with a link structure like this...

Home \ Cat1 \ Cat2

How can I make the parent category in ...
  Topic: Breadcrumb Help
ShamusMay

Replies: 2
Views: 7168

PostForum: General   Posted: Thu May 07, 2015 4:50 pm   Subject: Breadcrumb Help
I'm using Smarty, PHP and MySQL. Need help creating the correct PHP/SQL function for passing a breadcrumb trail to the Smarty template.

Trying to achieve a multi-level breadcrumb like this...

Ho ...
  Topic: Parent and SubCategory Drop Down Menu
ShamusMay

Replies: 8
Views: 14797

PostForum: General   Posted: Wed Apr 29, 2015 4:55 pm   Subject: SOLVED
Changed the operators from != to == and it started working.

// list of all categories
function getCategoriesList($include_subcats = false) {

$where = '';

if ($include_subcats == false) { ...
  Topic: Parent and SubCategory Drop Down Menu
ShamusMay

Replies: 8
Views: 14797

PostForum: General   Posted: Wed Apr 29, 2015 1:41 pm   Subject: Parent and SubCategory Drop Down Menu
My current Smarty code looks like this and it only shows the parent categories. The old syntax was working to display the parent categories too, so my issue is still that the subcats are not displayin ...
 
Page 1 of 2 Goto page 1, 2  Next
All times are GMT
Jump to:  


Powered by phpBB © 2001, 2005 phpBB Group
Protected by Anti-Spam ACP