Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6208305
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T05:47:12+00:00 2026-05-24T05:47:12+00:00

I have the following code: <?php $this->beginWidget(‘zii.widgets.jui.CJuiDialog’, array( ‘id’=>’mydialog’, // additional javascript options for

  • 0

I have the following code:

<?php
$this->beginWidget('zii.widgets.jui.CJuiDialog', array(
    'id'=>'mydialog',
    // additional javascript options for the dialog plugin
    'options'=>array(
        'title'=>'Confirmar',
        'resizable'=>'false',
        'autoOpen'=>false,
        'modal'=>true,      
        'buttons'=>array('Eliminar'=>'js:function(){deleteMessage();$(this).dialog("close");}',
                         'Cancelar'=>'js:function(){$(this).dialog("close");}',),
    ),
));?>
<div style="display:none">Do you confirm you want to delete the item?</div> 
<?php 
$this->endWidget('zii.widgets.jui.CJuiDialog');
?>

<input type="button" onclick="js:openDlg()" value="Open the dialog">
<script language="javascript" type="text/javascript">
    function openDlg(){
        $("#mydialog").dialog("open"); 
    }
</script>

This works PERFECTLY, until i needed to call jQuery’s .load() function. For testing purposes, i have a button which calls the .load() method (although supposedly it should be called when the doc is ready). If i hit the open dialog button before clicking this trial button, the dialog opens correctly. Else, it fails with the following error:

$(“#mydialog”).dialog is not a function
$(“#mydialog”).dialog(“open”);

Trial button:

<input type="button" onclick="js:load_wall()" value="Load Messages">
function load_wall(){
        var liga = $("#liga_id").val();
        $('#div_wall_messages').load('displayMessages',{liga_id: liga}, function(){

        });

Please, any help is more than welcome. This error is driving me crazy. thank you!!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-24T05:47:12+00:00Added an answer on May 24, 2026 at 5:47 am

    What’s displayMessages? Is it a page with scripts in it? Is it a page that includes another copy of jQuery? If you include a second copy of jQuery you will be overwriting your existing copy—possibly you are overwriting a jQuery that has the Dialog plugin loaded into it with a new one that doesn’t.

    If you want to load into a div and what you’ve got in the file being loaded is a full page of HTML (including <head>, <script>s et al), then you should only load the fragment of content (by id) that you want into your target. In all cases avoid load()ing HTML content that contains <script>; the results are, depending on circumstance, either nothing, or nothing sensible.

    Also js: in all your code above does nothing and should be omitted.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have the following code: if (include_once(dirname(__FILE__).'/file.php') || include_once(dirname(__FILE__).'/local/file.php') ) { This causes an
I have the following jquery code: jQuery(function(){ jQuery(select#rooms).change(function(){ var options = ''; jQuery.getJSON(/admin/selection.php,{id: jQuery(this).val(),
i have the following code : <input type=text value=<?php echo $_GET['msg']; ?>> This input
I have the following code in page1.php : <a href=page2.php onClick=javascript:callFlash();>Go to page</a> This
I have following code in php: $mode = $this->input->get('mode'); // may return string or
i've been working on this question since yesterday, i have the following code.. <?php
I have the following php code: <html> <body> <?php $_GET = Array('filename' => 'scores/score.sco&scoresize=10&action=VIEW&viewtype=HTML');
i have this following php code : $filename = '/front/style.css'; $cssfile='#h1{font-size:12px}'; if($id_file=fopen($filename, w+)) {
I have following PHP code $val=<div id=user.$row['cid']. userid=.$row['cid']. class=innertxt><img src=images/images.jpg width=50 height=50><strong>.$uname.</strong><ul> <li>Email: .$row['cemail'].</li>
I have the following php code, which has been snipped for brevity. I am

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.