pierre-yvesC
Admite hilos creados en los últimos 30 días: 2
Debates favoritos del foro
Este usuario no tiene debates favoritos.
Temas del foro creados
| Status | Debate | Supporter | Voces | Mensajes | Caducidad |
|---|---|---|---|---|---|
|
Two CPT with address field
Iniciado por: pierre-yvesC
en: Toolset Professional Support
Problem: The site had two custom post types (CPTs), each with its own address field used to display markers on separate Google Maps. While CPT#1 displayed correctly, CPT#2’s map showed no markers, and the user wondered if multiple address fields were unsupported. Solution: Confirmed that Toolset fully supports multiple CPTs and multiple address fields. The issue was not a limitation but a configuration mismatch. The user was advised to: Ensure the CPT#2 field is a genuine Address field (not text). Verify the field group is assigned to CPT#2. Configure the View/Block for CPT#2’s map to use the correct address field as its marker source. Relevant Documentation: https://toolset.com/course-lesson/displaying-a-list-of-posts-on-a-map/ https://toolset.com/course-lesson/installing-toolset-maps-and-adding-address-fields/ |
|
1 | 3 | 1 week, 1 day ago | |
|
Filtering doesn’t work.
Iniciado por: pierre-yvesC en: Toolset Professional Support |
|
1 | 6 | 2 weeks, 6 days ago | |
|
Wrong title ordering
Iniciado por: pierre-yvesC en: Toolset Professional Support |
|
1 | 7 | 1 month ago | |
|
Conditional with relatioship
Iniciado por: pierre-yvesC en: Toolset Professional Support |
|
1 | 5 | 1 month ago | |
|
Pagination split shows only 2 records
Iniciado por: pierre-yvesC en: Toolset Professional Support |
|
1 | 9 | 2 months, 1 week ago | |
|
hide parent if child is empty
Iniciado por: pierre-yvesC en: Toolset Professional Support |
|
1 | 11 | 6 months, 3 weeks ago | |
|
Displaying related child
Iniciado por: pierre-yvesC en: Toolset Professional Support |
|
1 | 7 | 7 months, 2 weeks ago | |
|
Filtering parent with child taxonomy
Iniciado por: pierre-yvesC en: Toolset Professional Support |
|
1 | 18 | 8 months ago | |
|
Add lines connecting Markers in a Google Map
Iniciado por: pierre-yvesC
en: Toolset Professional Support
Problem: I want to connect Google Map markers in a sequential line (A → B → C) without closing the loop back to the starting point (A). Solution: The issue arises when the last coordinate duplicates the first one, which closes the loop. The updated JavaScript provided ensures that if the first and last coordinates are identical, the last coordinate is removed to prevent the path from closing. Here’s the corrected code snippet:
jQuery(document).ready(function($){
function initMap() {
var mapid = 'map-2';
var map = WPViews.view_addon_maps.get_map(mapid);
var markers = WPViews.view_addon_maps.markers[mapid];
if (markers.length === 0) return;
var tripCoordinates = [];
var latLng;
// Loop over all the markers and create an array of lat/lng objects
for (var marker in markers) {
if (markers.hasOwnProperty(marker)) {
latLng = {
'lat': markers[marker].position.lat(),
'lng': markers[marker].position.lng()
};
tripCoordinates.push(latLng);
}
}
// Remove the last coordinate if it duplicates the first coordinate
if (tripCoordinates.length > 1) {
var firstCoord = tripCoordinates[0];
var lastCoord = tripCoordinates[tripCoordinates.length - 1];
if (firstCoord.lat === lastCoord.lat && firstCoord.lng === lastCoord
|
|
1 | 3 | 1 year ago | |
|
wpv-add-to-cart-message not diplaying on single product
Iniciado por: pierre-yvesC
en: Toolset Professional Support
Problem: The customer reports that the "Added to Cart" message is not displaying correctly on their product page, even though a previous similar issue had been resolved. The initial troubleshooting step of toggling the AJAX add to cart buttons did not resolve the issue. Solution: I identified that the issue was caused by a specific line of code in the template that interfered with the wpv-add-to-cart-message shortcode: [wpv-conditional if="( '[wpv-post-body]' eq '0' )" evaluate="false"]<h2>Description</h2>[/wpv-conditional] To fix, I went ahead and changed the conditional to use a custom function: The line in the template was changed to: <div class="col-sm-8">[wpv-conditional debug="false" if="( wpv_conditional_post_has_content() eq '0' )"]<h2>Description</h2>[/wpv-conditional] </div> I added the following check function to the theme's functions.php file:
function wpv_conditional_post_has_content($type, $object) {
$return = 0;
if ( $type == 'products' ) {
if ( empty( $object->post_content ) ) {
$return = 0;
} else {
$return = count($object->post_content);
}
}
return $return;
}
After that I tested it and the 'Description' title is being displayed correctly and so is the added to cart message. |
|
2 | 9 | 1 year, 5 months ago | |
|
Add to cart image or icon
Iniciado por: pierre-yvesC
en: Toolset Professional Support
Problem: I am trying to replace the 'Add to cart' text with an image or an icon but can't figure out how to do it using the shortcode variations. Solution: It is not possible to add an icon or text directly inside the add_to_cart_text attribute. Instead, use custom CSS to add it as a background image. Provide the URL where the shortcode is used and the URL of the image for further assistance in creating a CSS starting point. |
|
2 | 3 | 1 year, 6 months ago | |
|
Filtering taxonomy multiple selection
Iniciado por: pierre-yvesC en: Toolset Professional Support |
|
2 | 7 | 1 year, 7 months ago | |
|
Hide a product category
Iniciado por: pierre-yvesC en: Toolset Professional Support |
|
2 | 3 | 1 year, 10 months ago | |
|
child categories do not display
Iniciado por: pierre-yvesC en: Toolset Professional Support |
|
2 | 8 | 1 year, 12 months ago | |
|
[wpv-control-distance] move to location
Iniciado por: pierre-yvesC en: Toolset Professional Support |
|
2 | 15 | 2 years, 5 months ago |