Switching from image field

13 years 8 months ago #138896 by KatoKalin
Replied by KatoKalin on topic Re:Switching from image field
That´s not the answer I was hoping for. :pinch:
So that would need an additonal script to move all the files into the new structure.
I will have to sort that out before I will become a doc subscriber.

Please Log in to join the conversation.

13 years 8 months ago #138934 by krileon
Replied by krileon on topic Re:Switching from image field
KatoKalin wrote:

That´s not the answer I was hoping for. :pinch:
So that would need an additonal script to move all the files into the new structure.
I will have to sort that out before I will become a doc subscriber.

Yes, you could also just cut and paste them manually. Again I don't recommend changing a fields type.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in to join the conversation.

13 years 8 months ago #138996 by KatoKalin
Replied by KatoKalin on topic Re:Switching from image field

Yes, you could also just cut and paste them manually.


:laugh: :laugh: :laugh:

No. That would not work having 13000 users in the database. :woohoo:

Post edited by: KatoKalin, at: 2010/07/29 22:23

Please Log in to join the conversation.

13 years 8 months ago #139047 by krileon
Replied by krileon on topic Re:Switching from image field
Not much more to advise, if you have a program that can us regular expressions for moving files then it'd be no problem otherwise it'd be a nightmare moving all the files to the appropriate locations. The image field stores directly into images/comprofiler. The file field stores into images/comprofiler/plug_cbfilefield/USER_ID/.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in to join the conversation.

13 years 8 months ago #139087 by KatoKalin
Replied by KatoKalin on topic Re:Switching from image field
I beleive the plugin creates the necessary folders on the fly? That means the USER_ID folders are getting created when a file is uploaded and not at the time the plugin is installed?
This means I need to do a script that creates the necessary structure and copy the files.
However I need to create them the same way the plugin does, to not to interfere with the plugin or open security holes.
So what I need to know is:
1. Owner and group under which plug_cbfilefield/ and USER_ID/ are created. (www-data?)
2. What CHMOD settings to use for plug_cbfilefield/ and USER_ID/
3. Does the plugin create index.html and .htaccess files in any of these folders?
4. Is USER_ID/ just the userid of the user, like 34 or 1001 or is there any special naming convention (leading zeros or anyhing) or is the correct naming like USER_1001?

Please Log in to join the conversation.

13 years 8 months ago #139266 by krileon
Replied by krileon on topic Re:Switching from image field

I beleive the plugin creates the necessary folders on the fly? That means the USER_ID folders are getting created when a file is uploaded and not at the time the plugin is installed?

Yes the filefield will create the folders on the fly when the user uploads a file.

This means I need to do a script that creates the necessary structure and copy the files.

Yes, you can get the user id directly from the file it self (userid_randomstring.extension).

1. Owner and group under which plug_cbfilefield/ and USER_ID/ are created. (www-data?)

Public read and write. Root user.

2. What CHMOD settings to use for plug_cbfilefield/ and USER_ID/

0755

3. Does the plugin create index.html and .htaccess files in any of these folders?

index.html, but not .htaccess.

4. Is USER_ID/ just the userid of the user, like 34 or 1001 or is there any special naming convention (leading zeros or anyhing) or is the correct naming like USER_1001?

The actual users ID as seen in _users table, _comprofiler table, etc... There's no special naming.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in to join the conversation.

Moderators: beatnantkrileon
Time to create page: 0.333 seconds

Facebook Twitter LinkedIn