944,110 Members | Top Members by Rank

Ad:
  • PHP Discussion Thread
  • Unsolved
  • Views: 12096
  • PHP RSS
Nov 1st, 2006
0

AJAX and Smarty

Expand Post »
how to use AJAX with Smarty in php?
Similar Threads
Reputation Points: 10
Solved Threads: 0
Newbie Poster
mindzen is offline Offline
1 posts
since Nov 2006
Nov 2nd, 2006
0

Re: AJAX and Smarty

Good question I will finre and replay u

vssp
Reputation Points: 5
Solved Threads: 5
Junior Poster
vssp is offline Offline
197 posts
since Jul 2006
Nov 3rd, 2006
0

Re: AJAX and Smarty

Click to Expand / Collapse  Quote originally posted by mindzen ...
how to use AJAX with Smarty in php?
very interesting.. and probably quite useful.

There are some libs out there for AJAX that allow you to just define a <div> like:

[HTML]<div class="ajax" id="pagename.html"></div>[/HTML] and the div will load the page defined. (I wrote one that does the above and have seen others that have similar syntax)

Maybe that would be a start to work on. I have only looked at smarty but never used it so I'm not sure how to define new template variables but the thing would be to use smarty to generate the html above...

If someone could post up a solution to having smarty write out the following output:

<script type="text/javascript" src="ajax_lib.js"></script>

when the ajax part is loaded. And the something like the following when a user uses one of the variables:

[HTML]<div class="ajax" id="pagename.html"></div>[/HTML]

I would put together the javascript end...
Moderator
Reputation Points: 457
Solved Threads: 101
Nearly a Posting Virtuoso
digital-ether is offline Offline
1,250 posts
since Sep 2005

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in PHP Forum Timeline: Lookign for project based jobs
Next Thread in PHP Forum Timeline: connect one server from another server through script





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC