2012-05-31 3 views
3

안녕하세요 대화 상자의 텍스트 크기를 변경하고 싶습니다. 동적으로 대화 상자를 만들었습니다. 텍스트 크기를 변경해야합니다. 어떻게해야합니까? 친절하게 안내 해줍니다.jquery에서 대화 상자 텍스트 크기를 변경하는 방법

function validate_email(){ 
       window.$required = $("#dialog").dialog({ 
        width: 300, 
        height: 450, 

        autoOpen: false, 
          buttons: { 
       'Complete': function() { 
        checkstatus(userid); 
       } 
       } 
       }); 
      $required.html('Your account setup has been initiated. 
started.').dialog('open');//here my text 
      } 

답변

3

당신은 당신의 대화의 스타일 수정 .css()을 사용할 수 있습니다 : 당신이 및/또는 그 내부 요소에 대한 전체 대화의 글꼴을 설정할 수 있습니다 스타일 시트에서

function validate_email(){ 
    window.$required = $("#dialog").dialog({ 
     width: 300, 
     height: 450, 
     autoOpen: false, 
     buttons: { 
      'Complete': function() { 
       checkstatus(userid); 
      } 
      } 
    }).css("font-size", "20px"); 

    $required.html('Your account setup has been initiated. started.').dialog('open');//here my text 
} 
+0

나는 papaitians을 의심하고 있습니다. – user1324068

1

을 :

<style> 
#dialog { font-size: 25px; } 
#dialog h2 { font-size: larger; } 
#dialog div { font-size: 20px; } 
#dialog div.bigger { font-size: 150%; } 
#dialog p { font-size: x-small; background-color: blue; } 
</style> 

여기서 font-size property은 여러 가지 단위를 허용합니다.

위 예제의 마지막 줄에 표시된 것과 같은 방식으로 다른 CSS 속성을 설정할 수도 있습니다.

관련 문제