Make JDatabase::replacePrefix() public

39 views
Skip to first unread message

Captain Paralytic

unread,
May 5, 2012, 3:23:46 PM5/5/12
to joomla-de...@googlegroups.com
When debugging components it is useful to output the query using the getQuery() method. However the output still retains the table prefix placeholder (#__).

It would be good to be able to output the query with the prefix substitution already done.

The call $db->replacePrefix($db->getQuery()) will not work because the method replacePrefix is protected.

Whist it is possible to utilise this method by invoking php's reflection abilities (I have a plugin that I use to do this), there really should be no need to jump through such hoops just to use this very useful method.

Can we please simply declare it as public in the future? 

elin

unread,
May 6, 2012, 12:25:44 PM5/6/12
to joomla-de...@googlegroups.com
The place to discuss something like that would be on the platform list or you could just do a pull request proposing the change and someone will probably explain why it can't or shouldn't be changed or if it can be they'll take the pull request.


Elin

Michael Babker

unread,
May 6, 2012, 12:31:00 PM5/6/12
to joomla-de...@googlegroups.com
The replacePrefix() method is public in the current version of the CMS and Platform…

--
You received this message because you are subscribed to the Google Groups "Joomla! General Development" group.
To view this discussion on the web, visit https://groups.google.com/d/msg/joomla-dev-general/-/d7uNm9U1XwcJ.
To post to this group, send an email to joomla-de...@googlegroups.com.
To unsubscribe from this group, send email to joomla-dev-gene...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/joomla-dev-general?hl=en-GB.

Paul Lautman

unread,
May 7, 2012, 2:54:49 PM5/7/12
to joomla-de...@googlegroups.com

Hi El in,
Where do I find the platform list and where do I go to do a pull request?

--

Captain Paralytic

unread,
May 7, 2012, 3:31:08 PM5/7/12
to joomla-de...@googlegroups.com
So it is. I must have been working in a 1.7 environment. Great news.


On Sunday, 6 May 2012 17:31:00 UTC+1, Michael B. wrote:
The replacePrefix() method is public in the current version of the CMS and Platform…

From: elin <elin....@gmail.com>
Reply-To: <joomla-dev-general@googlegroups.com>
Date: Sunday, May 6, 2012 6:25 PM
To: <joomla-dev-general@googlegroups.com>
Subject: [jgen] Re: Make JDatabase::replacePrefix() public

The place to discuss something like that would be on the platform list or you could just do a pull request proposing the change and someone will probably explain why it can't or shouldn't be changed or if it can be they'll take the pull request.


Elin

On Saturday, May 5, 2012 3:23:46 PM UTC-4, Captain Paralytic wrote:
When debugging components it is useful to output the query using the getQuery() method. However the output still retains the table prefix placeholder (#__).

It would be good to be able to output the query with the prefix substitution already done.

The call $db->replacePrefix($db->getQuery()) will not work because the method replacePrefix is protected.

Whist it is possible to utilise this method by invoking php's reflection abilities (I have a plugin that I use to do this), there really should be no need to jump through such hoops just to use this very useful method.

Can we please simply declare it as public in the future? 

--
You received this message because you are subscribed to the Google Groups "Joomla! General Development" group.
To view this discussion on the web, visit https://groups.google.com/d/msg/joomla-dev-general/-/d7uNm9U1XwcJ.
To post to this group, send an email to joomla-dev-general@googlegroups.com.
To unsubscribe from this group, send email to joomla-dev-general+unsub...@googlegroups.com.

For more options, visit this group at http://groups.google.com/group/joomla-dev-general?hl=en-GB.

On Sunday, 6 May 2012 17:31:00 UTC+1, Michael B. wrote:
The replacePrefix() method is public in the current version of the CMS and Platform…

From: elin <elin....@gmail.com>
Reply-To: <joomla-dev-general@googlegroups.com>
Date: Sunday, May 6, 2012 6:25 PM
To: <joomla-dev-general@googlegroups.com>
Subject: [jgen] Re: Make JDatabase::replacePrefix() public

The place to discuss something like that would be on the platform list or you could just do a pull request proposing the change and someone will probably explain why it can't or shouldn't be changed or if it can be they'll take the pull request.


Elin

On Saturday, May 5, 2012 3:23:46 PM UTC-4, Captain Paralytic wrote:
When debugging components it is useful to output the query using the getQuery() method. However the output still retains the table prefix placeholder (#__).

It would be good to be able to output the query with the prefix substitution already done.

The call $db->replacePrefix($db->getQuery()) will not work because the method replacePrefix is protected.

Whist it is possible to utilise this method by invoking php's reflection abilities (I have a plugin that I use to do this), there really should be no need to jump through such hoops just to use this very useful method.

Can we please simply declare it as public in the future? 

--
You received this message because you are subscribed to the Google Groups "Joomla! General Development" group.
To view this discussion on the web, visit https://groups.google.com/d/msg/joomla-dev-general/-/d7uNm9U1XwcJ.
To post to this group, send an email to joomla-dev-general@googlegroups.com.
To unsubscribe from this group, send email to joomla-dev-general+unsub...@googlegroups.com.

For more options, visit this group at http://groups.google.com/group/joomla-dev-general?hl=en-GB.

On Sunday, 6 May 2012 17:31:00 UTC+1, Michael B. wrote:
The replacePrefix() method is public in the current version of the CMS and Platform…

From: elin <elin....@gmail.com>
Reply-To: <joomla-dev-general@googlegroups.com>
Date: Sunday, May 6, 2012 6:25 PM
To: <joomla-dev-general@googlegroups.com>
Subject: [jgen] Re: Make JDatabase::replacePrefix() public

The place to discuss something like that would be on the platform list or you could just do a pull request proposing the change and someone will probably explain why it can't or shouldn't be changed or if it can be they'll take the pull request.


Elin

On Saturday, May 5, 2012 3:23:46 PM UTC-4, Captain Paralytic wrote:
When debugging components it is useful to output the query using the getQuery() method. However the output still retains the table prefix placeholder (#__).

It would be good to be able to output the query with the prefix substitution already done.

The call $db->replacePrefix($db->getQuery()) will not work because the method replacePrefix is protected.

Whist it is possible to utilise this method by invoking php's reflection abilities (I have a plugin that I use to do this), there really should be no need to jump through such hoops just to use this very useful method.

Can we please simply declare it as public in the future? 

--
You received this message because you are subscribed to the Google Groups "Joomla! General Development" group.
To view this discussion on the web, visit https://groups.google.com/d/msg/joomla-dev-general/-/d7uNm9U1XwcJ.
To post to this group, send an email to joomla-dev-general@googlegroups.com.
To unsubscribe from this group, send email to joomla-dev-general+unsub...@googlegroups.com.

For more options, visit this group at http://groups.google.com/group/joomla-dev-general?hl=en-GB.

On Sunday, 6 May 2012 17:31:00 UTC+1, Michael B. wrote:
The replacePrefix() method is public in the current version of the CMS and Platform…

From: elin <elin....@gmail.com>
Reply-To: <joomla-dev-general@googlegroups.com>
Date: Sunday, May 6, 2012 6:25 PM
To: <joomla-dev-general@googlegroups.com>
Subject: [jgen] Re: Make JDatabase::replacePrefix() public

The place to discuss something like that would be on the platform list or you could just do a pull request proposing the change and someone will probably explain why it can't or shouldn't be changed or if it can be they'll take the pull request.


Elin

On Saturday, May 5, 2012 3:23:46 PM UTC-4, Captain Paralytic wrote:
When debugging components it is useful to output the query using the getQuery() method. However the output still retains the table prefix placeholder (#__).

It would be good to be able to output the query with the prefix substitution already done.

The call $db->replacePrefix($db->getQuery()) will not work because the method replacePrefix is protected.

Whist it is possible to utilise this method by invoking php's reflection abilities (I have a plugin that I use to do this), there really should be no need to jump through such hoops just to use this very useful method.

Can we please simply declare it as public in the future? 

--
You received this message because you are subscribed to the Google Groups "Joomla! General Development" group.
To view this discussion on the web, visit https://groups.google.com/d/msg/joomla-dev-general/-/d7uNm9U1XwcJ.
To post to this group, send an email to joomla-dev-general@googlegroups.com.
To unsubscribe from this group, send email to joomla-dev-general+unsub...@googlegroups.com.

elin

unread,
May 8, 2012, 2:29:09 PM5/8/12
to joomla-de...@googlegroups.com
Platform list:

Pull requests for the platform:
Pull requests for the CMS (must also put an issue in the tracker)


Elin



On Monday, May 7, 2012 2:54:49 PM UTC-4, Captain Paralytic wrote:

Hi El in,
Where do I find the platform list and where do I go to do a pull request?

On 6 May 2012 17:25, "elin" <elin....@gmail.com> wrote:
The place to discuss something like that would be on the platform list or you could just do a pull request proposing the change and someone will probably explain why it can't or shouldn't be changed or if it can be they'll take the pull request.


Elin

On Saturday, May 5, 2012 3:23:46 PM UTC-4, Captain Paralytic wrote:
When debugging components it is useful to output the query using the getQuery() method. However the output still retains the table prefix placeholder (#__).

It would be good to be able to output the query with the prefix substitution already done.

The call $db->replacePrefix($db->getQuery()) will not work because the method replacePrefix is protected.

Whist it is possible to utilise this method by invoking php's reflection abilities (I have a plugin that I use to do this), there really should be no need to jump through such hoops just to use this very useful method.

Can we please simply declare it as public in the future? 

--
You received this message because you are subscribed to the Google Groups "Joomla! General Development" group.
To view this discussion on the web, visit https://groups.google.com/d/msg/joomla-dev-general/-/d7uNm9U1XwcJ.
To post to this group, send an email to joomla-dev-general@googlegroups.com.
To unsubscribe from this group, send email to joomla-dev-general+unsub...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages