Note that there are some explanatory texts on larger screens.

plurals
  1. POjQuery automated content via .html(...)
    text
    copied!<p>I have a basic jQuery webpage that shows off some basic features, however there are some not so basic components as well. Some of my portions of the page require SQL queries via external PHP pages. These pages are feed into the main webpage via a GET, then inserted into a div. The code design to perform this action is shown below:</p> <pre><code>function changeSystem(sysName) { pageReq = "menu/"+group+"/"+sysName+".php"; $("#thesys").load(pageReq); stylize(); } </code></pre> <p>Stylize was created into a function to describe my styles (call via the function above and though the page creation):</p> <pre><code>function stylize() { $("#form").submit(function(event) {event.preventDefault();}); $(".tabs").tabs(); $("button").button(); $(".radioset").buttonset(); $(".sortable").sortable(); $(".sortable").disableSelection(); $(".accordion").accordion(); } </code></pre> <p>The response returns some buttons and fields according to the page creation. The code works great, to a point. The content is displayed, however the returned content is not stylized like all the other jQuery objects on the rest of the page. They show up as traditional buttons and fields throwing off the look and feel of the page. If I replace the automated content with static imbedded content, the buttons appear appropriately stylized. Do I need to call a specialized jQuery method to correct the style of this page for this new content?</p> <p><strong>EDIT:</strong></p> <p>The style that I am referring to is jQuery's theme via <a href="http://jqueryui.com/" rel="nofollow">http://jqueryui.com/</a>. The bordering style, colors and sizes do not carry over into the generated content. The theme of the buttons seem to resemble the default html theme.</p> <p><strong>SECOND EDIT:</strong></p> <p>Thank you pilotcam for those great recommendations. I have implemented your second recommendation with great success, however the second one I am still working on. The progress is shown above.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload