예제 #1
0
 /**
  * Get the JavaScript configuration for the iPhorm plugin
  *
  * @return string
  */
 public function getJsConfig()
 {
     $config = array('id' => $this->getId(), 'uniqueId' => $this->getUniqId(), 'useAjax' => $this->getUseAjax(), 'successMessageTimeout' => $this->getSuccessMessageTimeout(), 'resetFormValues' => $this->getResetFormValues(), 'clElementIds' => $this->getConditionalLogicElementIds(), 'clDependentElementIds' => $this->getConditionalLogicDependentElementIds(), 'centerFancybox' => $this->getCenterFancybox(), 'centerFancyboxSpeed' => $this->getCenterFancyboxSpeed());
     if (strpos(iphorm_get_http_referer(), 'iphorm_preview=1')) {
         $config['preview'] = true;
     }
     return iphorm_json_encode($config);
 }
예제 #2
0
파일: form.php 프로젝트: sabdev1/ljcdevsab
?>
>
            <input type="hidden" name="iphorm_id" value="<?php 
echo esc_attr($formId);
?>
" />
            <input type="hidden" name="iphorm_uid" value="<?php 
echo esc_attr($formUniqueId);
?>
" />
            <input type="hidden" name="form_url" value="<?php 
echo esc_attr(iphorm_get_current_url());
?>
" />
            <input type="hidden" name="referring_url" value="<?php 
echo esc_attr(iphorm_get_http_referer());
?>
" />
            <input type="hidden" name="post_id" value="<?php 
echo esc_attr(iphorm_get_current_post_id());
?>
" />
            <input type="hidden" name="post_title" value="<?php 
echo esc_attr(iphorm_get_current_post_title());
?>
" />
            <?php 
if (strlen($formTitle = $form->getTitle())) {
    ?>
                <h3 class="iphorm-title" <?php 
    echo $form->getCss('title');