I need a component for Joomla 2.5 to remind people about this website in certain time.
On frontend will be the form:
Remind me about this website on:
"email field"
|dd| |mm| |yyyy| / (date selector)
| remind |
So the component should create a cronjob on this date to send an email. Can you advice something, please? Or suggest any solution?
You definitely need to store a list of emails and dates in some table.
Cronjobs are outside of Joomla's domain and may not be set by Joomla.
So you would typically provide two solutions to your users:
Create a frontend task that performs the mailing: a dedicated controller/task in a custom component usually, something you would invoke with
index.php?option=your_component&task=cron
Echo the correct invocation string and ask your user to schedule it as appropriate.
Run a check in a plugin, so after rendering is complete you can perform your additional tasks. There will be no cronjobs since it will be run by Joomla itself on each site visit. You want to make sure your plugin doesn't invoke the function too often or it will kill the site.
Related
I'm new to Magento, so forgive my lack of knowledge. I am following a tutorial to integrate the contacts in Magento and import it to SugarCRM. The tutorial changes the core functions of Magento, but I would like to write a module and leave the core intact. I can easily find information about overriding controllers, models, helper, etc. But I have a question.
Imagining, for example, each time a user registers on my website, his contact information is exported to SugarCRM. In the save contact phase, in my module I know that I can write a specific code and tell that it would need to be run after or before some specific core-functions of Magento are done to save the contacts.What I really don't understand is, how will Magento know that I have a module that will perform me certain actions when I'm creating a new account?
The way magento handle this is by using events/observers. For instance, if you needed to send order information to another system after an order has been placed, you could create a custom module which observe sales_order_place_after.
Read more # http://codemagento.com/2011/04/observers-and-dispatching-events/
To get a list of events see https://magento.stackexchange.com/questions/153/where-can-i-find-a-complete-list-of-magento-events
For how to create an module with observer see https://stackoverflow.com/a/12696681/1191288
We want to build a bridge to synchronize data both ways in magento 1.6 and zoho crm -to synchronize leads, quotes, invoices, clients (assign them a user id and password for our B2B website) -to synchronize products attributes, etc...
Examples :
Each time a client fills up a form to be registered on my website it has to create a lead on magento like the first time login form ( i already made one web to lead form, but doesn't fit well with magento design and doesn't create the account in magento...)
Each time a client asks for a quote (through a form "Request a quote") on magento, it creates an opportunity, or a quote (or a lead ?).
I would like something really simple that adapts to magento structure that's all, in fact, it's a question of pushing/pulling DB records in both softwares (magento and zoho).
So I've been looking all around the web, but if you google "Zoho Magento integration" it will only return people ready to pay for that. Since I know magento a bit, I'm willing to do it by myself.
Thanks for Your help !
You will have to create a magento connector module to handle synchronization between Magento and ZOHO CRM API ( http://zohocrmapi.wiki.zoho.com/ ).
It is not easy. But if you have some experience with Magento development and do not know how to start with it, i would suggest you to download some similiar module (e. g. http://www.magentocommerce.com/magento-connect/integrations/crm/erply-connector.html) and see how it is built. Then try to develop your own.
I wrote a custom component in Joomla! that pulls in content from an XML feed and stores it in the Joomla database. I want the admin URL (/administrator/index?option=com_mycomp) to run via cron once every night to run the component. I can't figure out how to make this work, though, since the component is an administrator task and you have to be logged in to run it.
How do I get by this? I tried including my user/pw in the url (http:admin:password#www.mysite.com/joomla/administrator....) but it doesn't work. Is there anyway other way to send login credentials, or any other way to do this?
I know this thread is very old, but here's how I handled a similar task.
The "trick" is to take the custom PHP code you have created, and embed it into an article within your Joomla website.
I did this by using the JUMI extension, that allows custom PHP code to be stored within the Joomla repository and embedded, as required, within an article.
Then, create a CRON task that will activate the appropriate URL for the page containing the code you want to run.
Just put your script in the administrator directory of the component like
/administrator/components/com_yourcomponent/cron.yourcomponent.php
This is how FeedGator handles cron tasks [Sounds very similar to what you're trying to do.] ... you can also write a frontend controller in your component per one of the comments
========== [Update] ============
I created this ultra-simple installable component that could also be used for this purpose. It allows for a frontend menu item to be assigned to a php page (including the route as suggested). So you:
install the component
create new menu item, (may want to use a 'hidden' menu) select the 'show' view option and enter the script to run via cron in 'file to include' like path/yourcron.php
call the 'page' in your cron or test using: yourjoomlasite.com/index.php?option=com_show or yourjoomlasite.com/your-menu-alias
Mostly corn urls works from front-end even if your component deals with administrator only in Joomla.
So whatever your code in admin cron get it to front-end & so that your cronurl becomes like index.php?option=com_yourcomponent&task=cronjob.
Use this url to set cron using cPanel.
However this solution doesn't need to see whether admin is logged or not.
I am looking for a module/extension, or something that can help me to
make a page/item that only one specific user registered can see.
I would like also create a space dedicated to this user, where i can publish there pages and aticles.
Maybe using php and the variable that contains the username and an iframe, but I dont know how to doit.
Thank for the help
GMAccess is a Joomla! component that makes managing groups and access permissions easy, you will be able to create a special group and add your user (via Joomla's user management) to it and manage which pages can be viewed by that group.
I want to grab the User Object in Joomla in another PHP script.
Anway, what I want to do is grab the Joomla User (JUser) on a non-Joomla page. More or less I want a way to grab the joomla username, email and name etc and throw it to a php script for use in another custom application.
What is the best way to do this? Make a specialized joomla page by importing the framework, grabbing the necessary info from the user, setting those as session variables and then redirecting to the PHP page I want to use that information in?
Or do I just make some sort of link on a Joomla page with querystring variables corresponding to the current User and when they click the link I grab the info from the Querystring?
I'm looking for a best case scenario of how to get the User info to a custom application.
Any insight would be appreciated.
Best way would be to create a User plugin that logs into your script when someone logs into Joomla: Joomla unified logins for forum and a custom made php sub-site
depends on what you want the data for.
the juser data is serialised and stored in the session, so you could reverse engineer that and pull out the juser data... That would be messy.
alternatively you could make a plugin that stores the juser data in a session variable of your own making. the session variable will be available to other php scripts.. asuming they use the same session methods. (joomla has its own)
you could make a plugin that stores the data in a database that is assessible to the other script, or a flat file etc. in essence a similar process to using a session
You could also load up enough of joomla to use the joomla functions that you need to retrieve the juser values.. (messy)