#silverstripe IRC Log

IRC log for 5 May 2016

All timestamps are in UTC.

1: [00:00:01] * ss-helper quit (Remote host closed the connection)
2: [00:00:16] * ss-helper has joined #silverstripe
3: [00:00:44] * robbiea quit (Remote host closed the connection)
4: [00:16:16] * robbiea has joined #silverstripe
5: [00:16:50] * terryapodaca has joined #silverstripe
6: [00:17:23] <terryapodaca> Hey guys, this might be easier than I am trying to make it out, but here's what I am trying to accomplish
7: [00:18:10] <terryapodaca> I have a PurchasePage where users can select products to purchase and then check out via PayPal, but the plugin allows me to also have a "return" page.
8: [00:19:24] <terryapodaca> so what I would like to do is like how the search works, I want to come back to PurchasePage_results.ss template, but i don't want a new PHP controller, how do I process this in the PurchasePage.php controller to show?
9: [00:19:59] <Firesphere> have a public function results() in the controller
10: [00:20:02] <Firesphere> And allow the action.
11: [00:20:13] <robbiea> ^ that
12: [00:20:20] <robbiea> controllers can have many actions
13: [00:20:55] <micmania1> terryapodaca ^^ and SS works its magic and the _results.ss template will autmatically get selected based on the action name.
14: [00:22:31] <robbiea> but that being said, if PayPal is posting to your return URL then you should possibly process the results and redirect the user to a static page e.g. "success" to avoid the refresh -> are you sure you want to resubmit posted data issue
15: [00:23:48] <terryapodaca> robbiea: I was going to do that to begin with, but let me see how this works how Firesphere says to try first.
16: [00:23:53] <terryapodaca> I'll update in a few.
17: [00:23:57] <robbiea> cool
18: [00:24:28] <terryapodaca> and like micmania1 says, let SS work its own magic.
19: [00:24:45] <robbiea> in that case you'd need two actions - return() and results(), allow both in $allowed_actions and have return() validate the return data and redirect to results() afterwards. no template required for return(), only results()
20: [00:25:47] <terryapodaca> makes sense...
21: [00:26:43] <terryapodaca> I am not so sure I will need to process any return data though, not at this point at least...only show a "success" message. Which is why your second suggestion might be the most simple too
22: [00:35:50] <robbiea> it depends on what you're doing in your return action. if you're writing any data before displaying a message then you should redirect away from it once you've written. if you're not doing anything that would matter when you refresh the page a few times then it wont make a difference.
23: [00:49:17] <terryapodaca> do I need to specify a renderWith() or do I leave the function empty?
24: [00:52:49] * zlinux quit (Ping timeout: 252 seconds)
25: [00:58:12] * Stomach quit (Quit: zzz)
26: [01:11:20] * Stomach has joined #silverstripe
27: [01:12:55] <robbiea> only use renderWith() if it's a template filename that isn't what SS would expect (which I believe is ControllerNameHere_actionName.ss)
28: [01:13:11] <robbiea> e.g. for a template called "paypalreturn.ss" you'd have to say renderWith('paypayreturn') I believe
29: [01:34:41] * Tanger has joined #silverstripe
30: [01:46:54] * Stomach quit (Ping timeout: 276 seconds)
31: [01:58:01] * robbiea quit (Remote host closed the connection)
32: [01:58:38] * micmania1 quit (Quit: micmania1)
33: [02:02:00] * adrexia quit (Quit: My Mac has gone to sleep. ZZZzzz…)
34: [02:23:08] * micmania1 has joined #silverstripe
35: [02:23:14] * robbiea has joined #silverstripe
36: [02:35:01] * adrexia has joined #silverstripe
37: [02:38:18] * adrexia quit (Client Quit)
38: [02:46:53] * Phlunk3 quit (Quit: Leaving)
39: [02:59:21] * Stomach has joined #silverstripe
40: [03:17:08] * Hailwood has joined #silverstripe
41: [03:17:41] <Hailwood> Hey folks, anyone have any experience on saving a base64 encoded string as a SS Image?
42: [03:26:27] * robbiea quit (Remote host closed the connection)
43: [03:30:07] * nghtjr has joined #silverstripe
44: [03:30:37] <Stomach> yes!
45: [03:30:40] <Stomach> I do
46: [03:30:41] <Stomach> Hailwood
47: [03:30:56] * robbiea has joined #silverstripe
48: [03:31:50] <Stomach> http://pastie.org/private/iux5xdyrpub4y4rcmxjqg
49: [03:31:52] <Stomach> there ya go
50: [03:32:01] <Stomach> something like that
51: [03:44:26] <Hailwood> Thanks Stomach!
52: [03:45:08] <ss-helper> Re: [silverstripe-dev] Re: Preferred method for converting framework to PSR-2 - https://groups.google.com/d/msg/silverstripe-dev/IoMtKlju3Rc/8hV61YO-BwAJ
53: [03:45:09] <ss-helper> Re: [silverstripe-dev] Re: Preferred method for converting framework to PSR-2 - https://groups.google.com/d/msg/silverstripe-dev/IoMtKlju3Rc/vV-kNBa-BwAJ
54: [03:48:26] <Stomach> no worries Hailwood
55: [04:00:09] <ss-helper> Re: [silverstripe-dev] Re: PHP/Silverstripe IDE Survey : What IDE do you use for SS work ? - https://groups.google.com/d/msg/silverstripe-dev/bozY5hh9g4c/xGzP5Rm_BwAJ
56: [04:33:40] * adrexia has joined #silverstripe
57: [04:34:33] * adrexia quit (Client Quit)
58: [04:57:34] * robbiea quit (Ping timeout: 252 seconds)
59: [05:10:54] * Marc_doe quit (Ping timeout: 250 seconds)
60: [05:12:50] * Crashy quit (Quit: Leaving)
61: [06:00:13] <ss-helper> get values between two dates in silverstripe - http://stackoverflow.com/questions/37043284/get-values-between-two-dates-in-silverstripe
62: [06:06:47] * robbiea has joined #silverstripe
63: [06:13:00] * robbiea quit (Remote host closed the connection)
64: [06:22:44] * micmania1 quit (Quit: micmania1)
65: [06:36:46] * Stomach quit (Quit: zzz)
66: [06:50:12] * Mike123 has joined #silverstripe
67: [06:50:23] <Mike123> Hi everyone :)
68: [07:02:53] <terryapodaca> How come in the CMS there is an option for Title (attribute) on image uploads but the title attribute isn't written out on the front end?
69: [07:03:10] <terryapodaca> is this just an overlook in the rendering by the framework?
70: [07:05:43] * spronk quit (Quit: I may need a longer sleep timer...)
71: [07:07:19] * swaiba has joined #silverstripe
72: [07:20:20] <Mike123> can i filter record in gridfield my has_one relation
73: [07:20:48] * glenn-bautista quit (Quit: Leaving.)
74: [07:28:18] * spronk has joined #silverstripe
75: [07:33:21] <swaiba> yes Mike123 you can
76: [07:38:04] <Mike123> swaiba, i get inputs only from the DO itseld, the other two are has_one relation and i dont have inputs https://snag.gy/C3Gz8R.jpg
77: [07:38:15] * Hailwood quit (Remote host closed the connection)
78: [07:38:18] <Mike123> maybe you could please explain me what's going on
79: [07:38:45] <swaiba> I though you meant a different type of filter, like searchable fields
80: [07:40:10] <Mike123> can i get filters like there are in ModelAdmin, into my page ?
81: [07:40:59] <Mike123> https://snag.gy/MuJ1NB.jpg
82: [07:45:59] <Mike123> is there a possibility to make ANY kind of search in gridfield ?
83: [07:47:04] <swaiba> no Mike123, searching isn't possible at all
84: [07:47:53] <swaiba> there is only the searchable fields, search context and numerous other ways
85: [07:54:43] * terryapodaca quit (Quit: Leaving.)
86: [07:55:40] * Teddy_ has joined #silverstripe
87: [07:57:59] * marvanni has joined #silverstripe
88: [08:00:57] <Mike123> swaiba, but i need searching only on one tab
89: [08:01:07] * swaiba quit (Remote host closed the connection)
90: [08:13:57] * kinglozzer has joined #silverstripe
91: [08:14:39] * spronk quit (Quit: I may need a longer sleep timer...)
92: [08:21:32] * terryapodaca has joined #silverstripe
93: [08:22:42] <terryapodaca> I've got a function in my PurchasePage.php file called results() where I want to render a super simple page called PurchasePage_results.ss
94: [08:22:49] <terryapodaca> in that function I put: return $this->owner->renderWith(array('PurchasePage_results', 'PurchasePage'));
95: [08:23:31] <terryapodaca> the page is rendered, but it doesn't render it with my theme, it's just a simple html page without all my header/footer/styles, etc
96: [08:25:37] * NETim_ has joined #silverstripe
97: [08:26:11] * NETim quit (Ping timeout: 276 seconds)
98: [08:28:27] <kinglozzer> terryapodaca: $this->owner? Is PurchasePage an extension?
99: [08:28:47] <kinglozzer> Usually that happens when the theme is disabled (e.g. in admin), where are you triggering the render?
100: [08:28:49] * robbiea has joined #silverstripe
101: [08:29:05] <terryapodaca> I changed it to: $this->renderWith(array('PurchasePage_results', 'PurchasePage'));
102: [08:29:12] <terryapodaca> and I still get a blank theme
103: [08:29:40] <terryapodaca> and no, its not an extension, it's a basic custom PageType for my Products page
104: [08:30:16] <ss-helper> Re: [silverstripe-dev] Re: Preferred method for converting framework to PSR-2 - https://groups.google.com/d/msg/silverstripe-dev/IoMtKlju3Rc/9m12UrzNBwAJ
105: [08:30:16] <terryapodaca> In my CMS, under settings, I have my "american" theme selected
106: [08:32:39] <kinglozzer> terryapodaca: How about $this->renderWith(array('PurchasePage_results', 'Page')); ?
107: [08:33:13] <kinglozzer> If your action is named 'results' you shouldn't need to manually render, it should use that template automatically if you just return array();
108: [08:39:06] <terryapodaca> kinglozzer: I now get this error: http://najrae.com/purchase/results
109: [08:39:15] <terryapodaca> Fatal error: Cannot redeclare PurchasePage_Controller::results() in /home/najraevps/najrae.com/mysite/code/PurchasePage.php on line 106
110: [08:40:18] <terryapodaca> ah HA!
111: [08:40:35] <terryapodaca> I had function results() instead of function Results()
112: [08:40:50] <terryapodaca> it is case sensitive
113: [08:42:37] * Stomach has joined #silverstripe
114: [08:48:33] * agent44 has joined #silverstripe
115: [08:50:11] <Mike123> is there a way to filter by has_one relation in gridfield ?
116: [08:50:32] <Mike123> it only show input for field that this class has in DB directly
117: [08:56:18] <elgabbu> Hi Mike123 ... in the private static $summary_fields of the dataobject you are listing in the gridfield ... you can specify a field from the has_one relationship
118: [08:57:05] <elgabbu> should be something like 'HasOne.Field' => 'My Other Field'
119: [08:57:42] * gelignite has joined #silverstripe
120: [09:12:42] * robbiea quit (Remote host closed the connection)
121: [09:37:45] * spronk has joined #silverstripe
122: [09:43:21] * Stomach quit (Quit: zzz)
123: [09:44:49] * Stomach has joined #silverstripe
124: [09:51:35] * Stomach quit (Quit: zzz)
125: [09:53:19] * kerozene quit (Ping timeout: 260 seconds)
126: [09:57:11] * NETim_ quit (Ping timeout: 276 seconds)
127: [09:57:33] * NETim has joined #silverstripe
128: [09:59:18] <Mike123> elgabbu, i did the same thing as you mentioned, but there are no filter input fields on these columns
129: [10:00:01] * kerozene has joined #silverstripe
130: [10:01:22] <Mike123> only field that are directly on this class can be filtered
131: [10:01:27] <Mike123> fields*
132: [10:03:27] * EasyCo quit (Quit: Connection closed for inactivity)
133: [10:07:32] * phorloop has joined #silverstripe
134: [10:11:49] <marvanni> if it is a small has_one relation like SomeType or SomeTeam, you could create dropdown for that
135: [10:11:58] <marvanni> that filters on RelationID
136: [10:16:11] * spronk quit (Quit: I may need a longer sleep timer...)
137: [11:24:37] * zlinux has joined #silverstripe
138: [11:31:02] * terryapodaca quit (Quit: Leaving.)
139: [11:56:20] * marvanni quit (Quit: marvanni)
140: [11:58:46] * swaiba has joined #silverstripe
141: [12:01:46] <swaiba> btw kinglozzer got the same result for replacing the "link existing" with GridFieldAddExistingSearchButton from https://github.com/silverstripe-australia/silverstripe-gridfieldextensions/issues
142: [12:02:09] <swaiba> it's like exactly the same expiernce, I suspect if I looked the code would be the same as brices...
143: [12:02:15] <swaiba> thought I's let you know
144: [12:04:57] * swaiba quit (Remote host closed the connection)
145: [12:06:10] * UndefinedOffset has joined #silverstripe
146: [12:15:53] <Mike123> while uploading file i get this error in my server error log mod_fcgid: HTTP request length 132499 (so far) exceeds MaxRequestLen (131072)
147: [12:16:09] <Mike123> i changed the MaxRequestLen in apache config file but still getting it
148: [12:16:11] <Mike123> any ideas ?
149: [12:44:33] <kinglozzer> ty swaiba
150: [12:52:36] <cloph_away> you need to change it in the fcgi config → FcgidMaxRequestLen
151: [13:17:08] * phorloop quit (Quit: My laptop go to sleep. ZZZzzz…)
152: [13:19:10] * zlinux quit (Read error: Connection reset by peer)
153: [13:20:37] * zlinux has joined #silverstripe
154: [14:09:14] * muskie9 has joined #silverstripe
155: [14:48:06] * Mike123 quit (Ping timeout: 250 seconds)
156: [14:54:22] * Teddy__ has joined #silverstripe
157: [14:56:03] * shellbackpacific quit (Ping timeout: 246 seconds)
158: [14:57:29] * Teddy_ quit (Ping timeout: 276 seconds)
159: [14:57:53] * zlinux quit (Ping timeout: 265 seconds)
160: [14:59:45] * muskie9 quit (Quit: My Mac has gone to sleep. ZZZzzz…)
161: [15:00:01] * zlinux has joined #silverstripe
162: [15:02:47] * shellbackpacific has joined #silverstripe
163: [15:03:25] * muskie9 has joined #silverstripe
164: [15:50:05] * robbiea has joined #silverstripe
165: [15:54:33] * robbiea quit (Ping timeout: 240 seconds)
166: [16:20:54] * eightythree has joined #silverstripe
167: [16:29:21] * jcwacky quit (Ping timeout: 244 seconds)
168: [16:38:59] * jcwacky has joined #silverstripe
169: [16:50:33] * muskie9 quit (Quit: My Mac has gone to sleep. ZZZzzz…)
170: [16:52:17] * UndefinedOffset quit (Quit: Leaving.)
171: [16:54:29] * UndefinedOffset has joined #silverstripe
172: [16:56:26] * Teddy__ quit (Ping timeout: 276 seconds)
173: [16:57:08] * agent44 quit (Quit: zzz)
174: [16:58:34] * jcwacky quit (Ping timeout: 240 seconds)
175: [17:13:20] * jcwacky has joined #silverstripe
176: [17:13:29] * jcwacky quit (Client Quit)
177: [17:24:38] * UndefinedOffset quit (Quit: Leaving.)
178: [17:25:54] * UndefinedOffset has joined #silverstripe
179: [17:39:03] * micmania1 has joined #silverstripe
180: [17:43:43] * micmania1 quit (Ping timeout: 260 seconds)
181: [18:06:29] * zlinux quit (Ping timeout: 244 seconds)
182: [18:15:03] * muskie9 has joined #silverstripe
183: [18:16:42] * krofek_ has joined #silverstripe
184: [18:19:52] * krofek quit (Ping timeout: 260 seconds)
185: [18:31:09] * marvanni has joined #silverstripe
186: [18:32:40] * robbiea has joined #silverstripe
187: [18:36:54] * robbiea quit (Ping timeout: 246 seconds)
188: [18:43:54] * BrewNaked has joined #silverstripe
189: [18:55:42] * muskie9 quit (Quit: Textual IRC Client: www.textualapp.com)
190: [19:12:14] * Stomach has joined #silverstripe
191: [19:17:02] * marvanni quit (Quit: marvanni)
192: [19:25:58] * marvanni has joined #silverstripe
193: [19:26:35] * arnhoe has joined #silverstripe
194: [19:27:54] * micmania1 has joined #silverstripe
195: [19:29:06] * Stomach quit (Quit: zzz)
196: [19:32:37] * micmania1 quit (Ping timeout: 252 seconds)
197: [19:32:51] * Stomach has joined #silverstripe
198: [20:27:21] * Phlunk3 has joined #silverstripe
199: [20:33:14] * robbiea has joined #silverstripe
200: [20:45:50] * UndefinedOffset quit (Quit: Leaving.)
201: [20:46:45] * marvanni quit (Quit: marvanni)
202: [20:48:26] * arnhoe quit ()
203: [20:49:34] * zlinux has joined #silverstripe
204: [20:52:26] * robbiea quit (Quit: Leaving...)
205: [20:54:29] * zlinux quit (Ping timeout: 250 seconds)
206: [21:01:53] * zlinux has joined #silverstripe
207: [21:07:07] * glenn-bautista has joined #silverstripe
208: [21:29:03] * zlinux quit (Ping timeout: 240 seconds)
209: [21:29:40] * zlinux has joined #silverstripe
210: [21:35:37] * Hailwood has joined #silverstripe
211: [21:43:49] <Hailwood> Hey folks, I've got a site in dev mode (verified via Director::isDev()) and I'm trying to run a dev/tasks tasks, but it's throwing a 500 error. Issue being it's just showing the "live mode" 500 error page, and no error is getting logged. Any ideas?
212: [21:53:58] * zlinux quit (Ping timeout: 252 seconds)
213: [21:56:41] * micmania1 has joined #silverstripe
214: [22:09:30] * DimiStripe_alt has joined #silverstripe
215: [22:10:24] * DimiStripe quit (Ping timeout: 246 seconds)
216: [22:10:24] * DimiStripe_alt is now known as DimiStripe
217: [22:11:32] * gelignite quit (Quit: http://bit.ly/1kso8Ta)
218: [22:11:57] * micmania1 quit (Quit: micmania1)
219: [22:13:35] * micmania1 has joined #silverstripe
220: [22:21:26] * Marc_newbie has joined #silverstripe
221: [22:21:26] <ss-helper> Marc_newbie: Welcome to #silverstripe! Please ask your questions but don't leave too soon, we are a busy lot.
222: [22:41:24] * spronk has joined #silverstripe
223: [22:46:56] * eightythree quit (Ping timeout: 250 seconds)
224: [22:55:22] * phorloop has joined #silverstripe
225: [23:19:41] * zlinux has joined #silverstripe
226: [23:20:37] * willr has joined #silverstripe
227: [23:25:16] * Azure quit (Ping timeout: 252 seconds)
228: [23:30:00] * Admonish has joined #silverstripe
229: [23:30:49] * willr quit (Read error: Connection reset by peer)
230: [23:31:11] * willr has joined #silverstripe
231: [23:31:29] * Azure has joined #silverstripe
232: [23:34:41] <Admonish> Hey guys. So I have created a ModelAdmin subclass and placed it in a module however when I try to run a dev build I get 'Not found"
233: [23:41:49] * micmania1 quit (Quit: micmania1)
234: [23:42:45] * micmania1 has joined #silverstripe

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