Support Forum » User Profile

Forum Replies Created

Viewing 12 posts - 1 through 12 (of 12 total)
  • Author
    Posts
  • in reply to: Stuck number of custom fields in Edit Field Group #38158
    ben06ben06
    Participant

    Thank again Long for your valuable help!
    It worked when I determined the max number of input variables of the project, inserting:
    php_value max_input_vars 10000
    in the <Ifmodule> tags of the .htaccess file of my project.

    in reply to: Error while inserting $field_id in rwmb_after_save_post #38050
    ben06ben06
    Participant

    Thx a lot again, both of you Long and Kevin! 😉

    in reply to: Error while inserting $field_id in rwmb_after_save_post #37991
    ben06ben06
    Participant

    Thanks a lot for your knowledge and your time! 😉

    in reply to: Error while inserting $field_id in rwmb_after_save_post #37964
    ben06ben06
    Participant

    Of course, here's the part of the MetaBox used for that:

    
            [
                    'name'        => __( 'Group', 'kallyas' ),
                    'id'          => $prefix . 'pieces_jointes_et_dates',
                    'type'        => 'group',
                    'collapsible' => true,
                    'default_state' => 'expanded',
                    'save_state' => true,
                    //'group_title' =>  'Pièce intitulée {pieces_jointes}, importée le:  '. '{date_fichier}',
                    'group_title' =>  'Importée le:  {date_fichier}',
                    'clone'       => true,
                    //'clone_default' => false,
                    //'clone_as_multiple' => false,
                    'sort_clone'  => true,
                    'clone_default' => false,
                    'add_button' => esc_html__( 'Ajouter une autre pièce jointe', 'kallyas' ),
                    'fields'      => [
                        [
                            'name' => __( 'Pièce(s) jointe(s)', 'kallyas' ),
                            'id'   => $prefix . 'pieces_jointes',
                            'type' => 'file_upload',
                        ],
                        [
                            'name' => __( 'Date de dépôt du fichier', 'kallyas' ),
                            'id'   => $prefix . 'date_fichier',
                            'type' => 'bs_date',
                            //'std'  =>  'Entrez ici la date de saisie de la pièce',
                            'js_options' => array(
                                'format' => "dd/mm/yyyy",
                                'endDate' => "today",
                                'startView' => 0,
                                'minViewMode' => 0,
                                'maxViewMode' => 2,
                            ),
                            'required' => 1,
                        ],
                    ],
                ],
    
    
    in reply to: Adding metabox field data to the post title #24640
    ben06ben06
    Participant

    Thank you it works well!

    in reply to: Readonly attribute under condition #24638
    ben06ben06
    Participant

    Hi,

    Thank you for your answer.
    Where do I have to add the condition ?
    The condition is : if post_status = publish {$mark = true}

    
    $meta_boxes[] = [
            'title'      => esc_html__( 'Signature', 'text-domain' ),
            'id'         => 'signature',
            'post_types' => ['docs'],
            'context'    => 'normal',
            'priority'   => 'high',
            'fields'     => [
                [
                    'id'              => $prefix . 'signature_appli',
                    'name'            => "Signature",
                    'type'            => 'password',
                ],
            ],
            'validation' => array(
                'messages' => array(
                    'signature_appli' => array(
                        'required'   => 'You have to sign.',
                    ),
                ),
            ),
            'visible' => array(
                'when' => array(
                     array( 'post_status','=', 'attente_app'),
                     array( 'post_status','=', 'publish')
                 ),
                 'relation' => 'or'
            ),
        ];
    
    in reply to: Get the post id as value #24087
    ben06ben06
    Participant

    Thank you for the screen record.

    It's working well on back end but I need to get the post id when I submit the front end form trough a shortcode.

    As I said, i can't get the post id from $_GET because I use a plugin and the url is modified.
    I think I have to retrieve the post id with a global.

    in reply to: Get the post id as value #24085
    ben06ben06
    Participant

    Hi,

    Yes I tried the code but it still not working...

    I also tried this :

    $test = $GLOBALS['post']->ID;

    The variable retrieves the good post id but it's not working as a value...

    in reply to: Get the post id as value #24084
    ben06ben06
    Participant

    Hi,

    Yes I tried the code but it still not working...

    How is that possible?

    in reply to: Get the post id as value #24074
    ben06ben06
    Participant

    Here is the code that creates the metabox :

    https://pastebin.com/wmc5ufqB

    in reply to: Get the post id as value #24072
    ben06ben06
    Participant

    Hi,

    Thank you for the answer.

    But this is not working...
    I'm using a plugin (Betterdocs), maybe that is the reason why it is not working.

    The URL is xxxxxx.com/docs/doc-1/

    But when I try to echo the post ID on the layout page of the plugin, it is working well.

    Any other ideas ?

    in reply to: Add checkbox frontend and save meta #24024
    ben06ben06
    Participant

    Thank you for your answer!

Viewing 12 posts - 1 through 12 (of 12 total)