Yii Framework Forum: Script to open related local file, VERY USEFUL - Yii Framework Forum

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Script to open related local file, VERY USEFUL Rate Topic: -----

#1 User is offline   eduardoarandah 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 4
  • Joined: 22-May 12

Posted 07 March 2015 - 07:21 PM

When you are creating an application is very easy to get lost switching from file to file.
Model, Controller, View

Here's a script that checks what files are being used so you can click on it and make changes easily!!

1. Use firefox

2. Install extension "Local Filesystem Links"

3. Put this somewhere in your code:
<div style="float: right;" ">
<a href="file:///<?=Yii::getAlias('@app');?>\models\<?=ucwords(Yii::$app->controller->getUniqueId());?>.php">models\<?=ucwords(Yii::$app->controller->getUniqueId());?>.php</a><br>
<a href="file:///<?=Yii::getAlias('@app');?>\controllers\<?=ucwords(Yii::$app->controller->getUniqueId());?>Controller.php">controllers\<?=ucwords(Yii::$app->controller->getUniqueId());?>Controller.php</a><br>
<a href="file:///<?=Yii::getAlias('@app');?>\views\<?=Yii::$app->controller->getUniqueId();?>\<?=Yii::$app->controller->action->id;?>.php">views\<?=Yii::$app->controller->getUniqueId();?>\<?=Yii::$app->controller->action->id;?>.php</a>
</div>

0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users