How to stop ACCESS field content in the csv import to change automatically?

WordPress Business Themes Forums Responsive Themes Directory Theme How to stop ACCESS field content in the csv import to change automatically?

Discontinued - The forum content is out of date. For theme support please use our support desk here.

How to stop ACCESS field content in the csv import to change automatically?

July 24, 2014
Charles Charles
  • Charles
    Charles
    Senior Member 149 points

    Hi,
    WP 3.9.1 and DT 6.6.0

    We just noticed that when we restrict access of the listings by selecting the ACCESS field: Membership0 and Membership1 the system assigns the following content to the csv export for that listing:
    a:2:{i:0;s:1:”0″;i:1;s:1:”1″;}

    But, if we upload a csv with said content, the system automatically and/or internally changes it (the ACCESS field content) to the following:
    s:30:”a:2:{i:0;s:1:”0″;i:1;s:1:”1″;}”;

    The issue is that with the second content, the system does not restrict access to Expired Members. With the first one, it does and this is the one we need.

    So, we would like to know how to fix this issue:
    1. If we enter in the excel csv the following content:
    a:2:{i:0;s:1:”0″;i:1;s:1:”1″;}
    which is the one we need since we want to restrict listing access so that ONLY active/paid Memberships can VIEW listings contents, the system simply changes it after importing to s:30:”a:2:{i:0;s:1:”0″;i:1;s:1:”1″;}”;

    Our current workaround is import all listings, then go one by one and edit every listing by selecting the ACCESS field, but it is too time consuming. We need a not-too-time-consuming csv import workaround.

    Thanks!

    July 24, 2014 at 1:26 am
  • Charles
    Charles
    Senior Member 149 points

    Hi Mark,
    Would you please take a look at this issue?
    Thanks in advance!

    July 29, 2014 at 2:45 am
  • Charles
    Charles
    Senior Member 149 points

    Hi Mark,
    When you have time, would you please take a look at this issue or should we open a support ticket?
    Thanks!

    August 1, 2014 at 4:09 pm
  • Clive
    Clive
    Super Guru 1,818 points

    Open a support ticket Charles: http://www.premiumpress.com/ticket/

    August 1, 2014 at 9:38 pm
  • Charles
    Charles
    Senior Member 149 points

    Hi Clive,
    As instructed ticket was created: #VGM-861-23783
    Thanks.

    August 1, 2014 at 11:04 pm
  • Mark Fail
    Mark Fail
    Super Guru 12,814 points

    hi Charles

    The code for ‘access’ is saved as an array in WordPress, you cannot modify this and re-import as the import is a flat file and thus wont accept array values since there is no array support in the cSV plugin.

    August 2, 2014 at 4:50 am
  • Charles
    Charles
    Senior Member 149 points

    Hi Mark,
    Thanks for the reply.
    1. Any chance that we can update the ACCESS field for all listings via phpMyAdmin executing an SQL command?
    2. As an alternative, any chance that the ACCESS field content a:2:{i:0;s:1:”0″;i:1;s:1:”1″;} be converted to urlencode()d or rawurlencode() like mentioned in this link: http://www.tuxradar.com/practicalphp/5/11/0#null – If yes, what would be the php code to convert from serialized to urlencode()d / rawurlencode()? I am not a php expert but if you provide the php code, I know how to run it on my server to obtain the correct string and test it in the csv. Maybe it could work.
    I have to find a workaround to avoid having to edit every listing 1 by 1.

    Thanks again!

    August 2, 2014 at 1:10 pm
  • Charles
    Charles
    Senior Member 149 points

    Hi Mark,

    1. Any chance that we can update the ACCESS field for all listings via phpMyAdmin executing an SQL command? If yes, what would be the correct command?
    Thanks.

    September 1, 2014 at 10:36 am

  • Lisa
    Newbie 2 points

    I am having the same issue. Where else can be restrict access for listings on a mass scale. Doing it one by one is not an option for listings in mass. How about the editor on the php page?

    October 29, 2014 at 6:14 am
Viewing 9 posts - 1 through 9 (of 9 total)

Didn't find what you were after?

Chat with us now

or contact our support team