Hi
I have the below code:
add_shortcode('render-view', 'render_view_func');
function render_view_func($atts){
$render1 = render_view(array('title' =>'list books'));
$render = trim($render1) ;
return $render;
}
In a form I am calling this shortcode:
<div class="cred-field cred-field-appraisal-saved-research" >
[cred_field field='appraisal-saved-research' post='appraisal' value='[render-view]' urlparam='' readonly='true']
</div>
The form displays like this: The text area is empty and the content of render view is displayed after, followed by:
' urlparam='' readonly='true']
Which means that ... post='appraisal' value='[render-view]' urlparam... was broken
By the way, all this was working well before I move I upgrade my toolset plugins
thank you for helping
By the way, here the view loop:
[hide-it][wpv-layout-start][/hide-it]
[wpv-items-found]
[hide-it]<!-- wpv-loop-start -->[/hide-it]
[hide-it]<ul class="wpv-loop js-wpv-loop"> [/hide-it]
<wpv-loop>
<!-- [wpv-conditional if=" '[types field="year-of-publication" ][/types]' eq '[types field='admin-appraisal-year' id='6379'][/types]' "]--> [wpv-conditional if=" '[types field="acad-year-name" id="$acad-years"][/types]' eq '[types field='admin-acad-year' id='6379'][/types]' "]
[hide-it]
[/hide-it][types field='author1' separator=', '][/types] ([types field='year-of-publication' format='FIELD_VALUE'][/types]). [wpv-post-title], [wpv-if pub="wpcf-publication-publisher" evaluate="!empty($pub)"] [types field='address-publisher'][/types]: [types field='publication-publisher'][/types].[/wpv-if]([types field='publication-status'][/types]).
[hide-it]
[/hide-it]
[/wpv-conditional]
</wpv-loop>
[hide-it][/hide-it]
[hide-it]<!-- wpv-loop-end -->[/hide-it]
[/wpv-items-found]
[wpv-no-items-found]
[hide-it][wpml-string context="wpv-views"]-No books[/wpml-string][/hide-it]
[/wpv-no-items-found]
[hide-it][wpv-layout-end][/hide-it]
and here hide-it:
add_shortcode('hide-it', 'hide_it_func');
function hide_it_func(){
return;
}

Minesh
Unterstützer
Sprachen:
Englisch (English )
Zeitzone:
Asia/Kolkata (GMT+05:30)
Hello. Thank you for contacting the Toolset support.
Can you please tell me what kind of value the view is returning.
I'll have to review your current setup with your view and form. Can you please tell me your expected results as well as share admin access details and problem URL where you added the said form.
*** Please make a FULL BACKUP of your database and website.***
I would also eventually need to request temporary access (WP-Admin) to your site. Preferably to a test site where the problem has been replicated if possible in order to be of better help and check if some configurations might need to be changed.
I have set the next reply to private which means only you and I have access to it.

Minesh
Unterstützer
Sprachen:
Englisch (English )
Zeitzone:
Asia/Kolkata (GMT+05:30)
Can you please tell me what view you are using as I tried to search for the view with title "list books" but I could not able to locate it.
=> versteckter Link
Indeed, in my first message I simplified the problem for the support. The actual name of the view is:
list books per prof ay for appraisal

Minesh
Unterstützer
Sprachen:
Englisch (English )
Zeitzone:
Asia/Kolkata (GMT+05:30)
Thank you - could you please tell me with the following shortcode: [render-view-research-projects]
- What view you are using?
It seems you have added all those custom shortcodes to functions.php file and I do not have access to it.
add_shortcode('render-view-research-projects', 'render_view_research_projects_func');
function render_view_research_projects_func($atts){
$render1 = render_view(array('title' =>'list projects per prof ay for appraisal without description'));
$render = trim($render1) ;
return $render;
}
As I said, all these shortcodes were working fine. Things went wrong after a major update of wordpress/theme/toolset

Minesh
Unterstützer
Sprachen:
Englisch (English )
Zeitzone:
Asia/Kolkata (GMT+05:30)
You have this field that is not working:
[cred_field field='appraisal-saved-research' post='appraisal' value='[render-view]' urlparam='' readonly='true']
You said you are using the following view with [render-view]:
- versteckter Link
Now, if I assign the another shrotcode you created to the same field, for example:
[cred_field field='appraisal-saved-research' post='appraisal' value='[render-view-research-projects]' urlparam='' readonly='true']
As you can see that [render-view-research-projects] is successfully rendered now:
=> versteckter Link
You can change the the field='appraisal-saved-research' value as desired later on.
It seems the [render-view] is not using the view you mentioned. Why? because if I just empty the view loop and add just "hello" word to it, with render view it still displays the other results starts with "Amor, Y..." . I see following line of comment with your [render-view] output, Can you please check from where its coming from:
<!-- [wpv-conditional if=" '2022' eq '2022' "]-->
Can you please investigate what is the view you are using and it seems it's broken because I can see with the output there is a [wpv-conditonal] shortcode is wrapped with comment.
My issue is resolved now. Thank you!