#silverstripe IRC Log

IRC log for 23 August 2013

All timestamps are in UTC.

1: [00:03:03] <ss23> No, not work! :O
2: [00:03:51] * mirrors has joined #silverstripe
3: [00:06:13] <mirrors> hey everyone..i am trying to add a custom action to the cmsmain and have it working successfully...now I would like to add the pop up that appears in the top right when you save a page
4: [00:06:28] <mirrors> so I want to notify to the user that the action was a success
5: [00:06:36] <mirrors> where is this done in the js
6: [00:07:31] <guzzlefry> oh, I had to do this. One second. :P
7: [00:10:03] * spronk quit (Ping timeout: 256 seconds)
8: [00:10:14] <mirrors> oh I hope you can find it !
9: [00:12:37] <Pyromanik> mirrors: it must be in the return value somewhere
10: [00:12:50] <Pyromanik> just inspect the response and grep it
11: [00:13:00] <Pyromanik> ctrl+f, whatevers
12: [00:13:24] <guzzlefry> Well, I don't exactly remember what I did. :P
13: [00:13:45] <guzzlefry> $this->response->addHeader("X-Status", rawurlencode("Message that goes in popup")); <-- this is in the form action.
14: [00:14:00] <guzzlefry> mirrors: Did you extend LeftAndMain?
15: [00:14:01] <coldblooded01> what's the best way to add Image Upload Field in backend (CMS)?
16: [00:14:02] <mirrors> i have found where the message is added to the response that is showed in the pop up
17: [00:14:10] <coldblooded01> right now I'm doing
18: [00:14:11] <coldblooded01> static $has_many = array(
19: [00:14:12] <coldblooded01> "ImageGallery" => "Image"
20: [00:14:13] <coldblooded01> );
21: [00:14:16] <coldblooded01> $fields->removeByName("ImageGallery");
22: [00:14:17] <coldblooded01> $fields->addFieldToTab("Root.Main", $ifPortImage = new UploadField('ImageGallery', 'Portfolio Gallery Images'));
23: [00:14:18] <coldblooded01> $ifPortImage->setConfig('allowedMaxFileNumber', 100)->setFolderName('assets/');
24: [00:14:19] <coldblooded01> $ifPortImage->getValidator()->setAllowedExtensions(array('jpg', 'jpeg', 'png', 'gif'));
25: [00:14:19] <guzzlefry> eep
26: [00:14:21] <guzzlefry> pastebin!
27: [00:14:24] <coldblooded01> sorru
28: [00:14:25] <coldblooded01> sorry*
29: [00:14:39] <mirrors> yeah guzzlefry I can see that...now i need the js to make the pop up happen
30: [00:14:40] <guzzlefry> It's okay, I was bracing for more lines than actually showed up. :P
31: [00:14:59] <coldblooded01> http://pastebin.com/ubQP9NDz
32: [00:15:01] <coldblooded01> :)
33: [00:15:01] <guzzlefry> mirrors: Are you extending LeftAndMain?
34: [00:15:34] <guzzlefry> I might be able to just give you a paste of my stripped down code if so. :P
35: [00:15:55] <mirrors> guzzlefry: no i am not...i have added a custom button in to the getCMSFields that can ajax request any url..then i simply want to show the pop up with success
36: [00:16:04] <ss23> tfw bradly manning is now chelsea manning.
37: [00:16:22] <guzzlefry> mirrors: I'm guessing right now the buttons dont' actually show any response?
38: [00:17:22] <mirrors> i a tick icon in the button that gets changed to a loading symbol and then back to a tick...so i know when the loading has finished
39: [00:17:31] <mirrors> but adding the pop up aswell would be nice
40: [00:17:39] <guzzlefry> okay well
41: [00:17:49] <mirrors> this button calls a task that updates a feed
42: [00:17:59] <guzzlefry> An Ajax call, right?
43: [00:20:33] <Pyromanik> mm, X-Status seems like it's probably the go.
44: [00:20:40] <guzzlefry> http://bpaste.net/show/okizxntuXOdJLGFq3PMG/
45: [00:21:01] <guzzlefry> err
46: [00:21:15] <guzzlefry> "Updated Expiry Dates" being the message in the popup.
47: [00:21:47] <mirrors> guzzlefry: yeah an ajax call
48: [00:22:02] <guzzlefry> mirrors: ^ See if you can get anything from that paste.
49: [00:23:11] * nhorstmeier quit (Remote host closed the connection)
50: [00:23:35] <Pyromanik> guzzlefry: that's... complex.
51: [00:23:58] <guzzlefry> Pyromanik: It is? :P
52: [00:23:59] <Pyromanik> (getResponseNegotiator())
53: [00:24:14] <Pyromanik> hmm
54: [00:24:28] <guzzlefry> It did take me a day to figure out how to do what I wanted. :P
55: [00:24:33] <simon_w> ss23, I guess any name's better than Bradley :p
56: [00:24:40] <ss23> haha
57: [00:24:43] <Pyromanik> I'd have thought you'd just have to set the header then return $this
58: [00:25:28] <ss23> simon_w: I have a question bout short codes. It looks like in some cases, it'll escape the output from a shortcode function, and other times it doesn't. Is this just me messing up understanding, or does something like that exist?
59: [00:25:29] <guzzlefry> well, there's a good chance I'm doing it the wrong way.
60: [00:25:36] <coldblooded01> with image uploading from CMS
61: [00:25:48] <coldblooded01> how to has_many for images never gets attached properly?
62: [00:25:54] <coldblooded01> works fine for has_one
63: [00:25:54] <simon_w> ss23, ask Hamish :p
64: [00:26:02] <ss23> :<
65: [00:26:07] <simon_w> coldblooded01, yes many_many
66: [00:26:12] <coldblooded01> ah, :) cheers
67: [00:26:32] <simon_w> *use
68: [00:27:19] <coldblooded01> fixed
69: [00:27:26] <coldblooded01> after an hr of frustration
70: [00:27:29] <coldblooded01> thanks simon_w
71: [00:34:56] * nhorstmeier has joined #silverstripe
72: [00:37:24] * nhorstmeier quit (Remote host closed the connection)
73: [00:38:28] * jsQuestion quit (Ping timeout: 245 seconds)
74: [00:39:30] <mirrors> guzzlefry: and Pyromanik ...i am looking something more on the js side of things...I can see in LeftAndMain.js they call statusMessage("Validation failed.", "bad");
75: [00:39:43] <mirrors> that doesnt work unfortuately
76: [00:43:39] <mirrors> i dont want to trigger the notice message..or even set the notice message in php
77: [00:43:52] <mirrors> i just want to trigger the notice message in js
78: [00:46:48] <guzzlefry> Not sure if that's possible. Someone else probably knows better than I though.
79: [00:47:06] <mirrors> ok i now know they use the thirdparty jquery.notice.js file
80: [00:48:56] <mirrors> and statusMessage is a js function that calls jQuery.noticeAdd();....getting somewhere
81: [00:55:15] <mirrors> ok cool.... FYI guzzlefry you can just called statusMessage in your js to trigger that pop up..i had another error in my js
82: [00:55:23] <mirrors> cheers for the help anyways
83: [01:10:30] * Jayden90 has joined #silverstripe
84: [01:10:54] <ss23> Oh yeah, only took a government site down for like 5 mins while trying to edit that fix on live
85: [01:10:58] <ss23> :D
86: [01:13:30] <simon_w> I haven't had Peavers complaining about my code recently. It must work or something.
87: [01:13:40] <ss23> XD
88: [01:13:45] <ss23> He always complains about mine!
89: [01:14:09] <simon_w> Good for you!
90: [01:14:36] <simon_w> Now, to decide what to have for lunch. Probably going to be having maccas for dinner
91: [01:15:48] <ss23> simon_w: I already got lunch
92: [01:16:02] <simon_w> That doesn't help me make a decide!
93: [01:16:22] <ss23> :D
94: [01:16:25] <ss23> I just went to a cafe
95: [01:22:59] <ss23> Every time I'm about to push something to opensource - http://www.youtube.com/watch?v=vCadcBR95oU
96: [01:23:55] * zippy__ has joined #silverstripe
97: [01:24:20] <zippy__> afternoons
98: [01:24:26] <ss23> Afternoon, zippy__ ^.^
99: [01:27:50] * mirrors quit (Quit: Page closed)
100: [01:31:54] * spronk has joined #silverstripe
101: [01:33:33] <Pyromanik> /assets/*
102: [01:33:33] <Pyromanik> !/assets/.htaccess
103: [01:33:37] <Pyromanik> Why no work?
104: [01:33:40] <Pyromanik> (.gitignore)
105: [01:34:10] <ss23> watt
106: [01:34:19] <ss23> Pyromanik: * does not include . files
107: [01:34:27] <simon_w> Just git add assets/.htaccess?
108: [01:34:30] <ss23> Pyromanik: Use "assets" in the .gitignore, not /*
109: [01:34:43] <Pyromanik> ss23: hmm
110: [01:35:00] <Pyromanik> pretty sure that rule has worked in the past, but sounds legit, I'll give it a goskis.
111: [01:35:26] <Pyromanik> simon_w: want it automated as best it can be.
112: [01:37:06] <Pyromanik> is MySQLDatabase::set_connection_charset('utf8'); deprecated / default now?
113: [01:39:11] * willr has joined #silverstripe
114: [01:39:42] <Pyromanik> simon_w: what happens if I
115: [01:39:45] <Pyromanik> Class:
116: [01:39:50] <Pyromanik> extensions:
117: [01:39:54] * atmos has joined #silverstripe
118: [01:40:03] <Pyromanik> - classThatDoesntExist
119: [01:40:04] <Pyromanik> ?
120: [01:40:25] <Pyromanik> error?
121: [01:40:30] <Pyromanik> silent fails?
122: [01:40:48] <Pyromanik> error only in dev mode otherwise silent fails?
123: [01:42:05] <simon_w> Error
124: [01:42:11] <simon_w> of the fatal type
125: [01:42:14] <Pyromanik> right
126: [01:42:19] <Pyromanik> ta
127: [01:43:42] <Pyromanik> also, someone explain to me DI vs IoC? Or is DI just a way to implement IoC?
128: [01:44:21] * atmos quit (Ping timeout: 250 seconds)
129: [01:45:23] <willr> Lines of code :)
130: [01:45:35] <Pyromanik> willr: :<
131: [01:46:22] <ss23> willr: Do you know about shortcodes and the rules for when the return value of the function will be automatically escaped or not?
132: [01:46:38] <willr> ss23 RTFC?
133: [01:46:46] <ss23> I tried, a lot :P
134: [01:46:51] <Pyromanik> try harder!
135: [01:46:53] <ss23> I didn't see any *obvious* escaping, but it's obviously happening somewhere
136: [01:47:03] <Pyromanik> ss23: maybe in SSViewer?
137: [01:47:05] <ss23> Spent maybe 30 mins trying to figure it out last night, could not figure it out :<
138: [01:47:13] <Pyromanik> err, ViewableData
139: [01:47:14] <Pyromanik> obj
140: [01:47:16] <Pyromanik> or something
141: [01:47:21] <ss23> Well I thoguht it would be int he ShortcodeParser.php, since it has to be something different somewhere
142: [01:47:22] <willr> I figure it could wrap it in an HTMLText object
143: [01:47:24] <ss23> idk
144: [01:47:25] <ss23> I couldnt' find it anyway
145: [01:47:35] <ss23> willr: Well the point is that some data is escaped, some isnt'
146: [01:47:45] <ss23> I suspect it does some funky logic based on whether it has any <tags> in it
147: [01:47:46] <Pyromanik> yeh, auto type conversion from string to HTMLText
148: [01:47:48] <Pyromanik> probably
149: [01:48:20] <ss23> So returning "<img src=\"foobar\">"; etc doesn't escape, but returning "lol \" quotes are fun"; escapes the quotes
150: [01:48:35] <willr> Of course
151: [01:48:50] <ss23> Of course? As in, is that obvious?
152: [01:49:03] <ss23> Because it wasnt' to me, and I didn't see that behaviour documented, and I don't know where to read about it
153: [01:49:58] <Pyromanik> ss23: so you mean it's doubleescaping your "
154: [01:49:59] <Pyromanik> ?
155: [01:50:29] <ss23> Uh
156: [01:50:31] <ss23> Single escaping?
157: [01:50:38] <ss23> It changes it, in the page output, to &quot;
158: [01:50:54] <Pyromanik> oic, Convert::raw2xml
159: [01:51:14] <Pyromanik> ViewableData::XML_val
160: [01:51:16] <Pyromanik> or something like that
161: [01:51:19] <Pyromanik> or both
162: [01:51:32] <Pyromanik> maybe it's content negotiator?
163: [01:51:34] <Pyromanik> dunnoo
164: [01:52:55] <ss23> I'm interested in how it decides what to escape vs what to leave plain
165: [01:53:07] <ss23> Mainly because it's totally getting it completely wrong and escaping some stuff it shouldn't in the case of dms module
166: [01:54:58] <Pyromanik> ffs
167: [01:55:05] * Jayden90 quit (Quit: Jayden90)
168: [01:55:06] * priithansen quit (Quit: priithansen)
169: [01:55:07] <Pyromanik> /assets/*
170: [01:55:08] <Pyromanik> !/assets/.htaccess
171: [01:55:11] <Pyromanik> DOES work ss23
172: [01:55:15] <Pyromanik> I was just having a 'mare.
173: [01:55:22] <Pyromanik> ls != ls -a
174: [01:55:40] <Pyromanik> f'n post lunch downs.
175: [01:55:45] <ss23> wat
176: [01:55:55] <Pyromanik> idek
177: [01:55:57] * swordsmanz has joined #silverstripe
178: [01:56:10] <batbadger> so i have got my form working finally, and i have it calling a different method on the controller after success using return Controller::curr()->redirect("ShowSuccess") but now that page renders blank, rather than the default page template, do i have to explicitly produce a template in my "ShowSuccess" method?
179: [01:56:35] <Pyromanik> batbadger: umm
180: [01:56:44] <Pyromanik> you shouldn't be doing that
181: [01:56:53] <Pyromanik> well
182: [01:56:57] <Pyromanik> yes and no
183: [01:57:01] <Pyromanik> where did you put the action?
184: [01:57:20] <simon_w> batbadger, what are you returning from ShowSuccess?
185: [01:57:25] <Pyromanik> if it's on the controller just $this->redirect('ShowSuccess') will suffice
186: [01:58:05] <Pyromanik> if it's on the form I think there's a $this->Controller, so $this->Controller->redirect()
187: [01:58:11] <Pyromanik> just to keep it a wee bit cleaner.
188: [01:58:13] * atmos has joined #silverstripe
189: [01:58:24] <atmos> "doesn't support property or method 'entwine' -_-
190: [01:58:31] <Pyromanik> as simon_w says, you want to either return $this, or an array()
191: [01:58:45] <batbadger> maybe my approach is wrong, i have my forms success action redirecting to a different action on the parent controller (with above code)
192: [01:58:50] <Pyromanik> possibly array('Content' => 'thanks for your submission, etc')
193: [01:59:07] <batbadger> i assumed then i could rerender the page template and have it show a message rather than the form it usually shows
194: [01:59:08] <Pyromanik> batbadger: the form isn't a controller
195: [01:59:18] <batbadger> no, the form has an associated controller
196: [01:59:21] <Pyromanik> but it is a request handler
197: [01:59:24] <Pyromanik> batbadger: yeh
198: [01:59:39] <Pyromanik> so which controller are we talking about? the associated one or another one entirely
199: [01:59:42] <Pyromanik> ?
200: [02:00:22] <batbadger> so my thinking is that once the forms action is successful i can redirect back to the associated controller and tell it that it can show a slightly different template, i was doing that with a new action, but i see in some example they do it with a query parameter (success=1) but either way, is that the usual way to do it?
201: [02:00:37] <Pyromanik> batbadger: where have you defined the action
202: [02:00:38] <Pyromanik> ?
203: [02:00:43] <Pyromanik> on the Form, or on the Controller?
204: [02:00:52] <Pyromanik> (either is fine, btw)
205: [02:01:17] <batbadger> the form has an action once validation has completed, where it does the work with the form, but then the controller could have an action that gets called (redirected to) after the form action is finished
206: [02:01:23] <Pyromanik> batbadger: some examples you refer to that do it with a query param are old as the hills and people didn't really understand SS at that time.
207: [02:02:11] <Pyromanik> batbadger: yeah, but what I'm saying is that you can define your form action on the controller, or in your form definition itself if you've subclassed form.
208: [02:02:27] <Pyromanik> either way it's not really important to your original question
209: [02:02:54] <batbadger> it makes logical sense for it to be in the form because of the type of work it's doing, but now i want to signal the controller that everything went okay, and to show some different content, which is my question -- what's the prefered way to do that
210: [02:02:58] <Pyromanik> to which the answer is that the template should be picked up and used provided you're not returning something you shouldn't from your success action.
211: [02:03:13] <Pyromanik> batbadger: well
212: [02:03:20] * DigNZ quit (Quit: DigNZ)
213: [02:03:35] <Pyromanik> public function SuccessFunctionName() {
214: [02:04:10] <Pyromanik> return array('TemplateVariable' => $value, 'AnotherTempalteVar' => $anotherValue, 'Etc' => 'etc.');
215: [02:04:13] <Pyromanik> }
216: [02:05:29] <Pyromanik> and your form action (defined on your form subclass) doesn't need to use Controller::curr(), you can do $this->Controller()->redirect('SuccessFunctionName');
217: [02:05:44] <Pyromanik> just to show the relationship a bit better.
218: [02:06:05] <Pyromanik> although you probably want some kind of method_exists or something wrapping that if you can.
219: [02:08:11] <batbadger> yeah makes sense
220: [02:08:30] <Pyromanik> there's probably a more elegant solution.
221: [02:09:01] <Pyromanik> maybe
222: [02:09:41] <batbadger> how do i render with the default template? just return an empty array and it'll use the default?
223: [02:10:07] <Pyromanik> something like (from your form's action implementer) return $this->Controller()->customise(array('Content'=>'Thank you for submitting, etc.'));
224: [02:10:10] <Pyromanik> maybe4
225: [02:10:27] <Pyromanik> batbadger: yeh, return array();
226: [02:10:53] <batbadger> i think in a week or so i'll know silverstripe better than the company that has hired me to help them out :<
227: [02:10:59] <batbadger> keep having to ask you guys rather than their actual devs
228: [02:11:36] <zippy__> With a form field field can you specify a css class on the actual inptut element?
229: [02:11:50] <simon_w> addExtraClass
230: [02:12:47] <zippy__> That applies it to the div contanier
231: [02:12:53] <zippy__> not the actual input element it seems
232: [02:13:21] <simon_w> Should do both
233: [02:13:42] <Pyromanik> batbadger: haha, sadly not too uncommon.
234: [02:14:11] <zippy__> seems it does both, but I don't need the styles on both… rats
235: [02:14:18] <zippy__> hmphm
236: [02:14:22] <simon_w> Well, it's what you get
237: [02:14:50] <zippy__> sorted
238: [02:14:53] <zippy__> thakns :)
239: [02:15:37] <Pyromanik> zippy__: input.blah
240: [02:15:42] <zippy__> yea
241: [02:15:44] <Pyromanik> vs duv.blah
242: [02:15:47] <Pyromanik> err
243: [02:15:48] <Pyromanik> div
244: [02:15:49] <simon_w> .blah .blah
245: [02:15:51] <Pyromanik> dem duvz
246: [02:15:55] <Pyromanik> or that
247: [02:16:05] <Pyromanik> too specific though
248: [02:16:10] <Pyromanik> could be*
249: [02:18:15] <Pyromanik> heh, looks like github supports svn now
250: [02:18:33] <simon_w> Has for a while
251: [02:18:58] <Pyromanik> kinda funky
252: [02:19:09] <Pyromanik> can you 'push' with it?
253: [02:19:15] <Pyromanik> or is it fetch only?
254: [02:19:32] * Stomach quit (Quit: Leaving.)
255: [02:19:45] * UncleCheese quit (Quit: UncleCheese)
256: [02:20:42] <batbadger> what's the preferred way to nuke the validation error / session data for the form after it's been successful?
257: [02:21:04] <simon_w> batbadger, should happen automatically
258: [02:21:12] <batbadger> if i return to the page i notice you have a ContactForm_ContactForm object still floating around in Session
259: [02:21:34] <batbadger> could this just be some hangover from all the debugging and screwing around i've been doing
260: [02:21:44] <simon_w> That happens too
261: [02:22:20] <batbadger> i just tried with a new browser and it's still doing it
262: [02:26:41] <Pyromanik> ss23: where was the stack trace filter info again?
263: [02:26:54] * UncleCheese has joined #silverstripe
264: [02:27:06] <Pyromanik> batbadger: session::clear
265: [02:27:26] <ss23> Pyromanik: idk :O
266: [02:27:30] <Pyromanik> although I don't think it matters, all message stuff is wiped I think
267: [02:27:40] <Pyromanik> just the form data is still there, but empty.
268: [02:27:44] <Pyromanik> which is the important part
269: [02:27:50] <Pyromanik> ss23: hmm
270: [02:28:08] <Pyromanik> I think Imma fix this db details thing coming up since I'
271: [02:28:22] <Pyromanik> ve just remembered it exists, and I'm settting up a dev site and noticed it still exists
272: [02:28:55] <ss23> No idea, sorry. I remember talking about it though
273: [02:28:59] * atmos quit (Ping timeout: 250 seconds)
274: [02:29:30] * atmos has joined #silverstripe
275: [02:29:42] <Pyromanik> [Warning] mysqli::mysqli(): (28000/1045): Access denied for user 'userlol'@'localhost' (using password: YES), trace: mysqli->mysqli(localhost,userlol,passwordlol), MySQLDatabase.php:68
276: [02:29:56] <atmos> gah - handyman is such a prick
277: [02:30:04] <Pyromanik> at what is?
278: [02:30:48] <atmos> a little helper for our document management system syncing
279: [02:30:55] <ss23> lol
280: [02:31:02] <ss23> SilentOne? more like... STUPIDONE!
281: [02:31:03] <ss23> WAhahhaha
282: [02:31:13] <atmos> lol
283: [02:31:22] * Stomach has joined #silverstripe
284: [02:32:07] <atmos> why u no dropdown tree!
285: [02:34:18] <ss23> Dropdowns were totally borked for me in latest 3.1 last night
286: [02:35:36] <atmos> ss23: I only have one borked dropdown, it only displays as far down as parent, with no child
287: [02:35:36] <Pyromanik> ss23: is it acceptable to show username but not password?
288: [02:35:49] <Pyromanik> I guess so
289: [02:36:18] <ss23> Pyromanik: I would say it's acceptable to show both, considering it will only ever come up in development mode
290: [02:36:27] <Pyromanik> ss23: yeah I know, but it is what it is.
291: [02:36:48] <Pyromanik> what was filtered is now once again.
292: [02:39:02] <batbadger> maybe i have another problem with my validator, if i put in no value for a field that is required, hit submit, it has the appropriate error, then if i add a vlaue had hit submit (other fields fail validation btw) the message is still being shown on the filled in field
293: [02:39:45] <simon_w> You're using a custom Form template, right?
294: [02:39:51] <batbadger> i guess that i shouldn't just be testing message in the template? http://bpaste.net/show/cERnDQDOTvaLUCKCRU60/
295: [02:41:17] <simon_w> batbadger, remove the forTemplate() method from your Form subclass
296: [02:42:29] <batbadger> ahh, now it's perfect
297: [02:42:56] <ss23> OH: *someone runs across the office* "Are you debugging on the production server?!" "... shit."
298: [02:42:57] <batbadger> can you elaborate on what was happening
299: [02:43:19] <simon_w> The default forTemplate() method is what clears the validation stuff
300: [02:43:26] <batbadger> ahh
301: [02:43:31] <batbadger> thanks a lot
302: [02:43:47] <simon_w> For some reason, people seem to replace it so that they can provide a renderWith() that is exactly the same as the default one
303: [02:44:25] <batbadger> i think i probably blindly monged my copypasta out of an old tutorial
304: [02:44:54] <batbadger> thanks a lot, i feel like i have a better handle on how everything is working now
305: [02:45:35] <zippy__> ss23: oh snap!
306: [02:49:40] * Liquide quit ()
307: [02:51:15] <atmos> I can't stop writing farmework
308: [02:52:20] <ss23> lol
309: [02:55:34] <Pyromanik> farm E work.
310: [02:57:16] <irogue> afternoon ladies
311: [02:57:44] <ss23> hai irogue, ltns
312: [02:58:58] <Pyromanik> ltns?
313: [03:00:24] <irogue> wasnt i here yesterday? or was it the day before?
314: [03:02:34] <atmos> hmmmm TreeDropdownField has an entwine property?
315: [03:02:39] <atmos> da fuq
316: [03:03:09] <atmos> sigh
317: [03:03:39] <irogue> holy shitballs
318: [03:03:52] <irogue> slingshot's been having some packet loss last few days (in hams at least)
319: [03:03:56] <irogue> suddenly got really bad
320: [03:04:12] <irogue> 70% loss to APE!
321: [03:05:59] <ss23> damn
322: [03:06:32] <irogue> okay, that was just a spike, it's settled to about 11% now
323: [03:06:44] <ss23> oh good to know, 11% loss is all good
324: [03:06:45] <ss23> :P
325: [03:06:49] <irogue> has been ~0.5% for the last 2 or 3 days, they don't want to know about it
326: [03:08:20] <ss23> Advantages of being part of a team on github: I can restart the travis builds for projects when PR's fail just because the build was already failing
327: [03:08:24] <ss23> o/
328: [03:08:34] <ss23> Also, you know what would be an... interesting idea?
329: [03:08:39] <ss23> Automatically merging any PR's that pass tests
330: [03:08:54] <ss23> It would motivate people to a) write tests (since otherwise dodgy shit would get merged) and b) pass tests
331: [03:08:58] <ss23> :D
332: [03:09:06] <ss23> Like "omg don't merge this" needs to come with a failing test etc
333: [03:11:25] <atmos> http://sspaste.com/paste/show/5216d159868b1 do I need to include entwine on here? I'm getting a 'Object doesn't support property or method 'entwine' ' when including 'TreeDropdownField.js'
334: [03:11:56] <ss23> simon_w: I have a question about PRs. One of my PRs is failing travis because I made it before teh build was fixed for the repo, because it like, edits a file that was one of the bad ones... I guess my question is... can I rebase my PR to be against the latest master easily etc? rebase might not be the right word
335: [03:12:18] <simon_w> Yes, you rebase and force push
336: [03:13:28] <ss23> simon_w: Do you know of a quick link I can look at for the commands and order? I presume it's like... git checkout master, git pull upstream, git rebase something, git checkout new-branch, git rebase from master somehow, git commit -a --amend, git push -f?
337: [03:13:51] <simon_w> the contributing code docs
338: [03:14:23] <ss23> hmm, ty simon_w :D <3
339: [03:24:30] * atmos quit (Quit: Page closed)
340: [03:25:10] * atmos has joined #silverstripe
341: [03:26:01] * cloph_away has joined #silverstripe
342: [03:26:19] * cloph quit (Ping timeout: 264 seconds)
343: [03:32:25] * unsignedint quit (Read error: Connection reset by peer)
344: [03:32:36] * unsignedint has joined #silverstripe
345: [03:34:05] * unsigned_ has joined #silverstripe
346: [03:34:54] * unsignedint quit (Read error: Connection reset by peer)
347: [03:35:24] <batbadger> hey thanks simon_w, Pyromanik
348: [03:35:29] <batbadger> i seem to have sorted out this whole site now
349: [03:37:02] <atmos> lucky
350: [03:51:08] <atmos> 9 mins
351: [03:54:02] * nickmolhoek quit (Quit: nickmolhoek)
352: [03:54:11] <chrisrio> heh
353: [03:54:29] <chrisrio> the .jsp SS probably didn't write (AKA Westpacs online banking) is downnnnnnnn
354: [03:54:52] <mobiusnz> hey, where did the status field (published etc) go in SS3?
355: [03:56:47] <chrisrio> good question :/
356: [04:00:56] <mobiusnz> $surveyPage = SurveyPage::get()->filter(array("Status" => 'Published'))->First();
357: [04:00:58] <mobiusnz> doesn't work
358: [04:04:56] <chrisrio> Versioned::set_reading_mode("Live");
359: [04:05:02] <chrisrio> SiteTree::get();
360: [04:05:03] <chrisrio> (for example)
361: [04:05:50] <mobiusnz> chrisrio: hmm, reminds me of good ol curlopts
362: [04:06:57] <mobiusnz> actually, looks like that the default, so I can just remove the filter
363: [04:07:24] <chrisrio> :P
364: [04:07:31] <chrisrio> you can throw a delete request at me later.
365: [04:13:03] * simon_w throws ss23 at chrisrio
366: [04:13:06] <simon_w> Delete this! :p
367: [04:13:55] <ss23> :O
368: [04:14:00] <ss23> ;_;
369: [04:14:04] <mobiusnz> haha no friday for you
370: [04:14:42] * zippy__ quit (Ping timeout: 276 seconds)
371: [04:17:27] <chrisrio> not even the decency of proper headers or anything.
372: [04:18:17] <chrisrio> damnit westpac let me in
373: [04:21:48] <chrisrio> my money wont spend itself.
374: [04:24:31] <ss23> lol
375: [04:25:10] <simon_w> Maybe they're installing all those GCSB hooks
376: [04:25:15] <ss23> The later it gets into the day, the stronger the urge to make potentially server devistating commits to puppet.
377: [04:27:35] <chrisrio> no self respecting nerd should mis-spell devastating.
378: [04:27:52] <ss23> sorry
379: [04:27:55] <ss23> I thought it was wrong too
380: [04:28:08] <ss23> but I put it into chrome and it didnt' red line it so I was like "maybe I'm just a retard"
381: [04:28:11] <chrisrio> next someone will misspell the dagobah system
382: [04:28:24] <chrisrio> and then shit will get crazy
383: [04:29:21] <chrisrio> (I googled that - stupid spelling, nice work George)
384: [04:29:57] <ss23> XD
385: [04:32:33] <ss23> "show databases" -> "995 rows"
386: [04:32:34] <ss23> ffff
387: [04:35:39] <chrisrio> oooo
388: [04:36:32] * NitinShah has joined #silverstripe
389: [04:49:47] <wmk> g'morning everyone
390: [04:50:09] * willr quit (Quit: willr)
391: [04:50:10] <ss23> morning ^.^
392: [04:50:18] * NitinShah quit (Quit: Leaving)
393: [04:52:04] * coldblooded01 quit (Quit: coldblooded01)
394: [04:55:17] * UncleCheese quit (Quit: UncleCheese)
395: [04:55:37] * simon_w quit (Quit: This computer has gone to sleep)
396: [05:00:27] <chrisrio> all my FF tabs just went transparent
397: [05:00:29] <chrisrio> WHAT
398: [05:00:44] * Stomach quit (Quit: Leaving.)
399: [05:04:54] <ss23> :O
400: [05:04:56] <ss23> FIX IT
401: [05:06:41] <chrisrio> GCSB all up in my shit
402: [05:06:48] <chrisrio> looking through my tabs
403: [05:08:01] <Pyromanik> must be the weekend.
404: [05:08:02] * Pyromanik quit (Quit: leaving)
405: [05:08:33] <chrisrio> Pyro just left the office without pants on, again.
406: [05:08:42] <chrisrio> later gents!
407: [05:08:48] * chrisrio quit (Quit: Page closed)
408: [05:23:02] * pippy_ quit (Ping timeout: 240 seconds)
409: [05:31:33] * Mayazcherquoi is now known as Mayzie
410: [05:35:14] * pippy has joined #silverstripe
411: [05:50:34] * Stomach has joined #silverstripe
412: [05:57:04] * violetina has joined #silverstripe
413: [06:01:17] * mobiusnz has left #silverstripe
414: [06:06:28] * simon_w has joined #silverstripe
415: [06:14:52] * NitinShah has joined #silverstripe
416: [06:20:10] <NitinShah> Still stuck with rss and shortcode link not parsing correctly with ss3.1
417: [06:20:45] <NitinShah> Any suggestions to display the links in rss feed correctly?
418: [06:29:47] * Stomach quit (Quit: Leaving.)
419: [06:38:57] * violetina quit (Remote host closed the connection)
420: [06:39:30] <simon_w|air> Which 3.1?
421: [06:39:52] <NitinShah> yes 3.1
422: [06:39:59] <simon_w|air> Which one?
423: [06:41:47] <NitinShah> last beta version
424: [06:41:54] <simon_w|air> Try the RC
425: [06:42:27] <NitinShah> Will do it right now and get back, was this resolved in rc?
426: [06:42:32] <simon_w|air> No idea
427: [06:42:45] <simon_w|air> But you're running a development build from March
428: [06:49:44] * simon_w|air quit (Quit: Leaving)
429: [06:51:45] * rohitbanerjee has joined #silverstripe
430: [07:08:40] * zippy__ has joined #silverstripe
431: [07:08:55] * NitinShah quit (Quit: Leaving)
432: [07:11:05] * rohitbanerjee quit (Ping timeout: 250 seconds)
433: [07:14:06] * ARNHOE has joined #silverstripe
434: [07:20:25] * zippy__ quit (Quit: zippy__)
435: [07:27:36] * Bollig|DesignCty has joined #silverstripe
436: [07:34:12] * Valorez_ has joined #silverstripe
437: [07:52:05] * nickspiel quit (Ping timeout: 248 seconds)
438: [08:04:30] * kinglozzer has joined #silverstripe
439: [08:19:43] * nickspiel has joined #silverstripe
440: [08:26:14] * nickspiel quit (Quit: Leaving)
441: [08:43:13] * Bollig|DesignCty quit (Quit: Bollig|DesignCty)
442: [08:50:12] * Shrike_Finland has joined #silverstripe
443: [09:30:46] * LoveDuckie has joined #silverstripe
444: [09:38:37] * Bollig|DesignCty has joined #silverstripe
445: [09:43:58] * ARNHOE quit (Remote host closed the connection)
446: [10:19:17] * ARNHOE has joined #silverstripe
447: [10:22:50] * ARNHOE_ has joined #silverstripe
448: [10:26:47] * ARNHOE quit (Ping timeout: 246 seconds)
449: [10:27:06] * ARNHOE_ quit (Ping timeout: 245 seconds)
450: [10:32:00] * ARNHOE has joined #silverstripe
451: [10:33:35] * ARNHOE quit (Remote host closed the connection)
452: [10:34:10] * ARNHOE has joined #silverstripe
453: [10:38:51] * ARNHOE quit (Ping timeout: 276 seconds)
454: [10:41:45] * Bollig|DesignCty quit (Quit: Bollig|DesignCty)
455: [11:09:50] * swordsmanz_ has joined #silverstripe
456: [11:10:18] * swordsmanz quit (Ping timeout: 264 seconds)
457: [11:10:18] * swordsmanz_ is now known as swordsmanz
458: [11:25:07] * ARNHOE has joined #silverstripe
459: [11:38:28] * Zauberfisch__i quit (Read error: Connection reset by peer)
460: [11:39:14] * Guits has joined #silverstripe
461: [11:40:46] * PanPipes has joined #silverstripe
462: [11:49:50] * PanPipes quit (Remote host closed the connection)
463: [11:55:53] * UndefinedOffset has joined #silverstripe
464: [12:02:22] * Zauberfisch_ has joined #silverstripe
465: [12:12:05] * Zauberfisch_ quit (Read error: Connection reset by peer)
466: [12:16:34] * Bollig|DesignCty has joined #silverstripe
467: [12:30:18] * AlphaCactus quit (Read error: Connection reset by peer)
468: [12:30:46] * AlphaCactus has joined #silverstripe
469: [12:55:46] * g4b0_ has joined #silverstripe
470: [12:56:26] <g4b0_> hi al
471: [12:56:34] * priithansen has joined #silverstripe
472: [12:56:51] <kinglozzer> Hey
473: [12:58:09] * Bollig|DesignCty quit (Quit: Bollig|DesignCty)
474: [12:59:43] <g4b0_> how can I have a custom search form?
475: [13:00:36] <kinglozzer> Create a form, do the query manually :P
476: [13:01:12] <kinglozzer> ->where("Title LIKE '%foobar%'");
477: [13:03:51] <g4b0_> eheh
478: [13:04:00] <g4b0_> I found a better solution
479: [13:04:29] <g4b0_> I created a form with action=SearchForm
480: [13:04:41] <g4b0_> input with name Search
481: [13:04:48] <g4b0_> and it did the trick
482: [13:07:03] * LoveDuckie quit (Ping timeout: 276 seconds)
483: [13:17:12] * micmania1 has joined #silverstripe
484: [13:17:45] <micmania1> anybody had any luck getting an html editor working within widgets?
485: [13:23:12] * Shrike_Finland quit (Quit: Leaving.)
486: [13:25:53] <wmk> any phpstorm users around?
487: [13:28:23] * osterlaus has joined #silverstripe
488: [13:32:51] * ss23 quit (Ping timeout: 256 seconds)
489: [13:33:28] * ss23 has joined #silverstripe
490: [14:15:36] * C10ne has joined #silverstripe
491: [14:22:44] <micmania1> Lazy Loading strikes again! Argh!!!
492: [14:30:51] <kinglozzer> Anyone know off the top of their head if you can use the document management module with translatable out of the box?
493: [14:49:31] * osterlaus quit (Quit: Leaving.)
494: [14:54:15] <micmania1> Its amazing how easily lazy loading breaks things. I'm surprised more people don't have problems
495: [14:57:50] <C10ne> Anyone tried to add select all button for multi-selection in CMS? I see there's a request on github, but nothing more than that.
496: [14:59:00] * Nivery has joined #silverstripe
497: [15:01:02] * ss23 quit (Ping timeout: 240 seconds)
498: [15:01:58] * ss23 has joined #silverstripe
499: [15:08:57] * r3v3rb has joined #silverstripe
500: [15:21:50] <r3v3rb> hi everyone
501: [15:22:53] <r3v3rb> anyone feel up to the htaccess challenge of keeping index.html and / working as the directory index but all other calls forward to framework/main.php ?
502: [15:29:32] * jsQuestion has joined #silverstripe
503: [15:29:35] <g4b0_> is it possible to add a "hint" to a CMS field ?
504: [15:29:42] * jsQuestion quit (Client Quit)
505: [15:30:00] <AlphaCactus> you can try ->setDescription("yo momma uses this field");
506: [15:32:02] <micmania1> RewriteCond %{REQUEST_URI} !index.html$ - you could try adding something like that before RewriteRule for the framework r3v3rd
507: [15:32:31] <micmania1> r3v3rb*
508: [15:33:14] <r3v3rb> micmania1: testing ;)
509: [15:34:36] <r3v3rb> micmania1: the issue is the default domain of www.xyz.com/ redirects to framework/main.php if I specifiy index.html in the url it works fine without any changes to the htaccess file
510: [15:35:03] <r3v3rb> i need to ensure that '/' does not redirect to framework/main.php
511: [15:35:06] <r3v3rb> somehow
512: [15:35:56] <g4b0_> thx AlphaCactus, I solved with setRightTitle()
513: [15:36:00] <r3v3rb> and just changing your !index.html$ to !/ works a treat
514: [15:36:05] <r3v3rb> thanks micmania1
515: [15:36:12] <micmania1> yeah, something like that lol
516: [15:37:30] <g4b0_> they do the same thing ...
517: [15:37:49] <AlphaCactus> g4b0_: yeah that works too. i used that before 3.1
518: [15:41:38] <wmk> AlphaCactus, setRightTitle doesn't work in 3.1?
519: [15:42:21] <AlphaCactus> uhh, setDescription just seems more natural of a name
520: [15:42:33] * ARNHOE quit (Remote host closed the connection)
521: [15:50:10] * ARNHOE has joined #silverstripe
522: [15:51:06] <kinglozzer> Love the Github repo name suggestions
523: [15:51:17] <kinglozzer> 'turbo-octo-hipster'
524: [15:56:50] * g4b0_ quit (Quit: Sto andando via)
525: [15:59:38] * kinglozzer quit ()
526: [16:07:33] * r3v3rb quit (Ping timeout: 248 seconds)
527: [16:09:25] * ARNHOE quit (Remote host closed the connection)
528: [16:28:12] * LoveDuckie has joined #silverstripe
529: [16:32:36] <guzzlefry> Does the Blog module work on SS3.1?
530: [16:33:09] * LoveDuckie quit ()
531: [16:37:39] <micmania1> I tried to use it and had a few issues with widgets but other than that I think its okay.
532: [16:45:24] <guzzlefry> micmania1: I take it you can't add blog entries via backend?
533: [16:46:36] <micmania1> I'm not sure. I ended up using my own as I was nearly done at the time :p
534: [16:46:45] <guzzlefry> ah
535: [16:47:09] <guzzlefry> I'm guessing pagination is pretty easy with SilverStripe?
536: [16:47:21] <guzzlefry> If so the requirements for this should be really easy to do without the module.
537: [16:47:49] <micmania1> https://github.com/micmania1/silverstripe-blogger - if you're interested.
538: [16:49:14] <micmania1> you can use PaginatedList to handle the pagination.
539: [16:55:23] * micmania1 quit (Quit: Leaving)
540: [17:37:10] * Nivery quit (Quit: Nivery)
541: [18:14:50] * Nivery has joined #silverstripe
542: [18:37:10] * priithansen quit (Quit: priithansen)
543: [18:37:44] * Nivery quit (Quit: Nivery)
544: [18:46:12] * Shrike_Finland has joined #silverstripe
545: [19:06:50] <guzzlefry> Is there a way to override the default blogholder.ss rather than editing the one in the Blog module?
546: [19:15:19] * micmania1 has joined #silverstripe
547: [19:15:35] <guzzlefry> Well nevermind. Seems I just add my modified template to themes. :P
548: [19:24:52] * Nivery has joined #silverstripe
549: [19:28:10] * Nivery quit (Client Quit)
550: [19:45:02] * UndefinedOffset quit (Read error: Connection reset by peer)
551: [19:50:29] * BPower has joined #silverstripe
552: [19:51:05] <BPower> The property to edit if I want to change the URL of a page programmatically is $this->URLSegment, right?
553: [19:52:59] <wmk> guzzlefry, correct. Afaik you can make a seperate subtheme like mytheme_blog for changed blog templates
554: [19:53:10] <wmk> when mytheme is the current theme
555: [19:53:39] <wmk> BPower, yes
556: [19:53:57] <wmk> $this->URLSegment defines the url in cms
557: [19:57:14] <BPower> wmk: Thanks!
558: [19:58:39] * cloph_away is now known as cloph
559: [20:04:04] * pippy_ has joined #silverstripe
560: [20:05:01] <BPower> If an image already exists somewhere on my server, but not in the model yet, and I want to attach it to a DataObject, what's the suggested method?
561: [20:05:35] <BPower> I have $img = new Image(); $img->loadUploadedImage( ... ); $img->write(); $dataObject->ImageID = $img->ID;
562: [20:05:44] <BPower> that's my best guess
563: [20:06:05] <micmania1> that should do, as long as you're only after a has_one on your dataobject
564: [20:06:22] <BPower> yep
565: [20:06:24] <BPower> thanks micmania1
566: [20:06:34] <FrozenFire> BPower, Unfortunately, there's no *easy* method for that.
567: [20:06:39] <FrozenFire> You can't use loadUploadedImage()
568: [20:06:45] <BPower> Hey FrozenFire - been a while
569: [20:06:50] <BPower> aww really?
570: [20:07:00] <FrozenFire> That will make use of PHP's file upload stuff, which won't work if you haven't actually had a file upload.
571: [20:07:12] <FrozenFire> Yeah, not sure if Evan ever got in touch with you
572: [20:07:18] * pippy quit (Ping timeout: 264 seconds)
573: [20:07:20] <FrozenFire> We've been swamped on a couple fronts. :)
574: [20:07:39] <BPower> FrozenFire: that's fine, I've been swamped too. I'll be in touch when we're ready. I have a project in mind.
575: [20:07:39] <FrozenFire> I just finished on http://www.callfire.com/blog/2013/08/22/the-all-new-callfire-php-sdk
576: [20:08:30] <BPower> FrozenFire: I passed an array with the same elements that it's looking for (like a php upload tmp_file array). Are you sure this won't work either?
577: [20:08:40] <FrozenFire> Certain.
578: [20:09:06] <FrozenFire> http://thefrozenfire.com/gtkgrab/caps/119e2a.png
579: [20:09:20] <FrozenFire> Some logic from a Wordpress to SilverStripe-blog importer I wrote
580: [20:09:37] <FrozenFire> You really just need to make sure the file exists under the ASSETS_DIR, and then set the Filename for a new Image
581: [20:09:39] <FrozenFire> And then write the Image
582: [20:09:57] <BPower> reading it now
583: [20:11:00] <BPower> yikes.
584: [20:11:09] <FrozenFire> A lot of that logic can be ignored. :)
585: [20:11:35] <FrozenFire> Basically, just make sure it's in the ASSETS_DIR
586: [20:11:42] <BPower> why not just use http://php.net/copy instead of file_get-contents -> file_put_contents?
587: [20:11:42] <FrozenFire> And then set the Image Filename
588: [20:12:15] <FrozenFire> I probably could've ;)
589: [20:12:16] <BPower> Oh, because you only have the URL, not the path
590: [20:12:33] <BPower> probably would've been smart to translate it into a path
591: [20:12:55] * pippy has joined #silverstripe
592: [20:13:08] * toddmorey has joined #silverstripe
593: [20:13:10] <FrozenFire> I think my reasoning was that I wanted to know whether I received any data, before writing anything.
594: [20:13:17] <FrozenFire> Versus, say, a 404
595: [20:13:39] <BPower> file_exists()?
596: [20:13:45] <FrozenFire> That'd be two requests
597: [20:14:09] <FrozenFire> Either way it'll basically do exactly what I did
598: [20:14:10] <BPower> still faster than downloading from HTTP
599: [20:14:14] * pippy_ quit (Ping timeout: 240 seconds)
600: [20:14:16] <FrozenFire> Not really
601: [20:14:21] <FrozenFire> It'll load it into memory either way
602: [20:14:23] <FrozenFire> And then write it
603: [20:14:30] <FrozenFire> And then free the memory
604: [20:15:02] <BPower> but you're downloading it via HTTP (over the network) into memory, instead of loading the file directly from the disk to the memory
605: [20:15:18] <FrozenFire> Yes. Because the file exists remotely, through HTTP
606: [20:15:38] <BPower> so, skip the network - less load
607: [20:15:44] <FrozenFire> There's no skipping to be done.
608: [20:15:48] <FrozenFire> The file isn't anywhere local
609: [20:15:56] <BPower> OH
610: [20:15:57] <BPower> ok
611: [20:15:59] <FrozenFire> ;)
612: [20:16:07] <FrozenFire> Had to download it either way
613: [20:16:49] <BPower> makes sense now
614: [20:17:32] <toddmorey> Inside of a ShortCodeHandler, I'm trying to call a function of the page. However, doing that results in the error of "Using $this when not in object context". Anyone have any ideas of how I can integrate dynamic data from a Page function into the $Content of a page (with or without shortcodes)?
615: [20:18:09] <FrozenFire> toddmorey, Shortcodes should not be interacting with the request directly.
616: [20:18:17] <BPower> btw, FrozenFire, ->loadUploadedImage will copy the file into the _assets dir and append the correct number (if one already exists). Then from there, you can set ->Filename, Title, etc
617: [20:18:20] <FrozenFire> They should be considered stateless in relation to the request.
618: [20:18:47] <toddmorey> yeah, I think that's what I'm learning through this exercise
619: [20:19:22] <guzzlefry> Does the Blog Module have any docs? Other than what I can find on the github project page.
620: [20:19:33] <guzzlefry> I'm trying to figure out how to add a search widget.
621: [20:20:38] <FrozenFire> BPower, By the by, loadUploadedImage is deprecated ;)
622: [20:20:55] <FrozenFire> Though maybe not until 3.2
623: [20:21:12] <BPower> that's fine - this is a one time script anyways
624: [20:21:14] <BPower> thanks
625: [20:21:42] <FrozenFire> I could've sworn it used move_uploaded_file
626: [20:22:11] <FrozenFire> There was something else where I was handling file uploads where I encountered the issue
627: [20:22:46] * swordsmanz quit (Quit: ooh ponies kinkeyyy)
628: [20:22:52] <FrozenFire> guzzlefry, Blog entries exist as pages
629: [20:23:00] <FrozenFire> So you should be able to use the regular search functionality
630: [20:23:05] <FrozenFire> Though... good luck with that
631: [20:23:11] <FrozenFire> It always caused me problems.
632: [20:23:16] <guzzlefry> oh goodie. :P
633: [20:28:28] * lietzmk has joined #silverstripe
634: [20:42:13] * zippy__ has joined #silverstripe
635: [20:44:08] <micmania1> Is there a reason SS_Datetime::now() wouldn't work within DataList->filter("somedate:GreaterThan", SS_Datetime::now())
636: [20:44:30] <micmania1> Its returning an empty value when I'm testing and I have to wrap it in strtotime()
637: [20:46:20] <BPower> FrozenFire: is it okay to not set ParentID?
638: [20:46:38] <FrozenFire> BPower, Yeah, that's functionality for something else, iirc.
639: [20:47:29] <micmania1> ah, I see what i've done.
640: [20:47:51] <micmania1> SS_Datetime::now()->Nice() should work. That's been annoying me for about an hour lol
641: [20:48:31] <FrozenFire> micmania1, Someone might disagree, but I wouldn't suggest using SS_Datetime for that sort of thing.
642: [20:48:46] <FrozenFire> If it's SQL-related, just use DateTime
643: [20:49:33] <micmania1> Its for unit testing. i'm setting a mock time with SS_Datetime.
644: [20:49:43] <micmania1> Nice() diesn't seem to be working either.
645: [20:49:53] <FrozenFire> SS_Datetime is largely for the template
646: [20:50:42] <micmania1> so I shouldn't be using it to test time-related stuff? Is there anything I should be using?
647: [20:50:48] <FrozenFire> DateTime
648: [20:51:08] <micmania1> does that keep the value of the mock time?
649: [20:54:46] <FrozenFire> Haven't a clue what you're speaking of when you say mock time.
650: [20:56:49] <BPower> FrozenFire: Thoughts? http://goo.gl/e85igk
651: [20:57:36] <micmania1> http://api.silverstripe.org/3.1/source-class-SS_Datetime.html#112-127 - It says its good for unit testing but I just grep'd the framework tests and its not being used. Brilliant.
652: [20:57:37] <BPower> fyi: $customer_path = Upload::$uploads_folder.'/customers/customer-name'
653: [20:57:42] <FrozenFire> What's your goal?
654: [20:58:40] <BPower> FrozenFire: same as before - copying an existing file on the server to the uploads dir and setting it to the LogoID ($data will be passed to new SomePage($data))
655: [20:59:15] <FrozenFire> Was more asking about the overall goal. I might have a better solution.
656: [20:59:55] <BPower> Overall, I'm converting 100+ flat PHP files w/ images into SS.
657: [21:00:08] <FrozenFire> Ah
658: [21:00:18] <FrozenFire> Probably correct, then.
659: [21:00:24] <BPower> thanks
660: [21:00:45] <FrozenFire> Though, hrmm
661: [21:00:51] <FrozenFire> Not sure about your path logic.
662: [21:01:07] <FrozenFire> Nor about your use of $_SERVER['DOCUMENT_ROOT']
663: [21:01:18] <FrozenFire> There are SS-defined constants for things like this.
664: [21:01:23] <FrozenFire> E.g. BASE_PATH and ASSETS_DIR
665: [21:01:50] <BPower> _SERVER['D - R'] is for the flat PHP side - outside of SS.
666: [21:01:59] <FrozenFire> So... how do you have access to Image?
667: [21:02:00] <FrozenFire> ;)
668: [21:02:15] <FrozenFire> Oh, wait, I see.
669: [21:02:18] <BPower> I'm confident in the paths, just not in the use of Image()
670: [21:02:57] <FrozenFire> The use of image looks *okay*, as long as the Filename includes the ASSETS_DIR at the beginning
671: [21:03:50] <micmania1> Figured out my issue. It works if you cast the return SS_Datetime::now() to a string.
672: [21:06:23] <BPower> ->toString()
673: [21:06:25] <BPower> cool
674: [21:06:44] <BPower> FrozenFire: yep Upload::$uploads_folder takes care of that
675: [21:06:55] <BPower> wait
676: [21:07:35] <BPower> I need both in 3.0.3. 3.1 has UPLOADS_DIR (or similar)
677: [21:08:32] <guzzlefry> So, it seems that $SearchForm doesn't uh, find anything.
678: [21:08:56] <BPower> FrozenFire: ASSETS_PATH.'/'.Upload::$uploads_folder should do the trick
679: [21:09:59] <guzzlefry> Any ideas?
680: [21:12:49] <guzzlefry> oh derp, I need a result page.
681: [22:05:48] * swordsmanz has joined #silverstripe
682: [22:09:44] * BPower quit (Remote host closed the connection)
683: [22:49:22] * lietzmk quit (Quit: Leaving)
684: [22:56:40] * pippy_ has joined #silverstripe
685: [22:57:38] * pippy quit (Ping timeout: 245 seconds)
686: [23:24:37] * willr has joined #silverstripe
687: [23:47:09] <C10ne> Anyone tried to add select all button for multi-selection in CMS? I see there's a request on github, but nothing more than that.

These logs were automatically created by ss-log on irc.freenode.net.