I created a layout module 7m (layouts). Each layout has about 15-20 fields (including eating and one repeater with fields). There comes a moment when I can not create more fields. And nothing else is stored. A begins to persist if you remove one field. Then another one I can keep.
How can I fix this problem?
Change (screen http://awesomescreenshot.com/08835dz3eb )
But dont work
This is a complete number of fields that can be added (if you add one more), nothing happens. New fields do not appear.
http://awesomescreenshot.com/0f635h2s43
44 filds (all including repeater ) in 7 Layout
I really need to solve this problem. I need at least another 10 fields.
Few solutions you can try..
Increase max_input_vars value from 3000 to 5000 or more.. (it worked for me after increasing value)
This method is if increasing max_input_vars does not help..
Quoted from ACF forum :
“I had the same problem and it turned out that because the server was using the Suhosin patch I also needed to set the following my .htaccess file:
suhosin.post.max_vars = 20000
suhosin.request.max_vars = 20000″
As mentioned by Rahul, 'max_input_vars' and suhosin settings in php.ini are the solution.
But what I would like to add to make this solution complete. You could get into case when migrating to other server or vps, where default setting for "max_input_vars" is 1000 or less and then You try to add new field which will result in all fields that was not in limit to disappear as from AFC administration or from POSTS also! .
So even if you fix the php.ini that leaves you with broken db.
Anyways solution is simple after setting 'max_input_vars' move that ACF field group to Trash, and restore it fields will be back ...
I hope it will save time to someone sometime.
I have the same problem yesterday. I solve this by increasing value of Blog pages show at most and Syndication feeds show the most recent in Setting -> Reading -> Heres the option.
In my WP dashboard, the default is 10.
Related
Got an unusual problem that started recently and wonder if anyone has any ideas why it's happening and how to stop it.
Some of my products are getting an underscore added to the url when selected which, naturally, results in a 404 error. It's consistent - either an underscore gets added or it doesn't. It doesn't seem to be related to the GUID or the post_name in the wp_posts table. It also doesn't matter if you call it using the URL or the post ID so the following:-
Bad index.php?page_id=1075707 the-john-rutter-christmas-piano-album-2 https://website-name.com/product/the-john-rutter-christmas-piano-album-2/
Good index.php?page_id=1087442 the-john-rutter-piano-album https://website-name.com/product/the-john-rutter-piano-album/
Bad index.php?page_id=1159681 parable-for-harpsichord https://website-name.com/product/parable-for-harpsichord/
Good index.php?page_id=1159684 jesu-meine-freude-2 https://website-name.com/product/jesu-meine-freude-2/
Bad here meaning that the URL appears with an underscore such as
https://website-name.com/product/parable-for-harpsichord_/
I've also tried this with every single plugin, except WooCommerce, de-activated and with my functions.php disabled. No difference.
I've tried using the URLs as given above, C&P or typed in manually and by directly referencing the post ID (as shown).
This has only recently started and I'm at a bit of a loss here. I don't know how widespread this problem is either since I've over 120,000 products and can't check them all by hand. Fortunately, this isn't live yet.
Any suggestions or ideas here would help me.
There appears to be a hidden character at the end of the post_name field. Deleting and recreating the field got rid of the problem.
User select date, time and then search
After click "Search Availability", it is needs to show all the available product within the provided date and time slot.
Using "WooCommerce Bookings" extension, how to do it?
I have customized both WooCommerce & Booking Extension:
To save bookable product :
woocommerce-bookings/includes/class-wc-bookings-admin.php
Method executes saving :
save_product_data( $post_id ) at line 434
File for searching listing page:
woocommerce/templates/archive-product.php
Skip loading boooking:
/wp-content/plugins/woocommerce-bookings/includes/booking-form/class-wc-booking-form.php
skip loading date time:
/wp-content/plugins/woocommerce-bookings/assets/js/booking-form.js
/templates/single-product/add-to-cart/booking.php
I tried to solve it as database driven solution first but data seems like unstructured. Also without identifying the Property and Method at the Code, you won't be able to make any customization. Doing customization the plugin and extension is easy but he hard part is understand the code structure and flow. Once you get it, you may do any level of customization.
There are lots of files (.PHP,JS) you needs to check but I have made it narrow for you. You only check the mentioned file above and can do your modification most of the case.
I just can't findAll() make return anything even though I am able to access a specific record by findByUid().
I have taken note (and tried to workaround / set up) of the typoscript solution and the record storage page bug without any success.
I am using a dummy extension code made by the extension builder in TYPO3 (current version) for your convenience. I have tested with data manually added through the TYPO3 config ui.
Any help would be much appreciated.
All the best and thanks in advance
Mario
For 99.9 % you didn't set your storagePid properly, it has to be the PID of the page where your records are stored. Effect: findAll() uses this PID to filter the records, while findByUid(uid) ignores PID (it searches by UID wherever record is stored.
Go to the main page > Templates and make sure that you included TypoScript from your new ext, then go to constant editor and set proper PID of page with your records. Clear whole cache at the end!
Also you can debug your SQL statement like in this answer, most probably at the end of statement you'll see something like AND your_table_name.pid IN (0) which definitely means that you didn't set storagePid or you didn't clear the cache.
I have a rather old page, where a lot of file upload input fields reside. The problem is, only the first 25 upload field's data gets populated after the post.
I'm using nginx+php5.3-fpm
max_file_uploads is set to 200, so that can't be the problem. There are also a lot of other input fields besides the file inputs, and they arrive just fine, all of them.
Any ideas, where should I look?
I GOT IT! It was suhosin's own restriction in effect:
suhosin.upload.max_uploads is set to 25
I would like to restrict the fields while creating a new post in WordPress. For the title, it should not exceed 40 characters. For the content, it should not exceed 400 characters. If these maximum values are exceeded, I would like to show an error message and not let the user continue. How do I do that in WordPress?
You should be able to use wordpress filters to modify the code that gets outputted when the editor is called. Essentially you would want to use it to insert some javascript and an extra div tag to display your error, then just read the contents of the "editorcontainer" id and show the error once it reaches a certain character limit.
I don't have the time at the moment to write a case example, but depending on your skill level, the functions you are looking for are:
apply_filters("the_editor", "customfunction_limitarea");
Where customfunction_limit area is your created function to insert the javascript. You can see how the_editor is currently called and how the default filters are applied in "wp-includes\general-template.php" on line 1822. The default looks like this:
$the_editor = apply_filters('the_editor', "<div id='editorcontainer'><textarea rows='$rows'$class cols='40' name='$id' tabindex='$tab_index' id='$id'>%s</textarea></div>\n");
I would try modifying that statement by placing a new filter in a functions.php file located in your themes directory, that way you don't have to worry about it getting over-written during an update. Otherwise, if you absolutely have to edit the wordpress core (generally a no-no), general_template.php would be the place to do it I think.
Essentially just read up on wordpress filters a little bit (be warned there's not a ton of documentation or examples available for it other than the basic stuff), and that should provide everything you need. The input verification end is easy enough to find scripts, just google jquery post limiting. Something like this might be exactly what your looking for:
http://swiki.fromdev.com/2010/02/jquery-maximum-limit-texttextarea-with.html