Skip to content

Commit

Permalink
fixed error report location
Browse files Browse the repository at this point in the history
  • Loading branch information
cws13003 committed Dec 5, 2017
1 parent 53fec36 commit 677ed0f
Show file tree
Hide file tree
Showing 7 changed files with 12 additions and 18 deletions.
2 changes: 1 addition & 1 deletion www/application/config/config.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
| a PHP script and you can easily do that on your own.
|
*/
$config['base_url'] = 'http://twitter-clone.lndo.site/';
$config['base_url'] = 'http://' . $_SERVER['HTTP_HOST'] . '/';

/*
|--------------------------------------------------------------------------
Expand Down
4 changes: 1 addition & 3 deletions www/application/views/home.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,7 @@
<h1>All Tweets</h1>

<?php $this->load->library('form_validation'); ?>
<?php echo validation_errors(); ?>
<?php //echo form_open('all_tweets/search_keyword'); ?>
<form class="form" action="all_tweets/search_keyword" method="post">
<form class="form" action="/index.php/all_tweets/search_keyword" method="post">
<div class="form-group">
<input type="text" name="keyword" class="form-control" placeholder="What would you like to find?">
</div>
Expand Down
3 changes: 1 addition & 2 deletions www/application/views/login.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
<?php
$this->load->library('form_validation');
echo validation_errors();
echo form_open('login');
?>
<div class="login container">
Expand All @@ -15,7 +14,7 @@
<input class="form-control" type="password" name="password" value="<?php echo set_value('password'); ?>" placeholder="Enter password"/>
<?php echo form_error('password'); ?>
</div>
<button type="submit" class="btn btn-primary">Submit</button><span> or <a href="register">Create an account</a></span>
<button type="submit" class="btn btn-primary">Login</button><span> or <a href="register">Create an account</a></span>

</form>

Expand Down
1 change: 0 additions & 1 deletion www/application/views/register.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
<?php
$this->load->library('form_validation');
echo validation_errors();
echo form_open('register'); ?>
<div class="login register container">
<img class="icon reg" src="../img/twitter.png" alt="Twitter">
Expand Down
2 changes: 2 additions & 0 deletions www/application/views/templates/footer.php
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
<br><br>
<em class="footer">&copy; 2017 Stingh Design</em>
<br><br>
<script type="text/javascript" src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
</body>
Expand Down
15 changes: 6 additions & 9 deletions www/application/views/user.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,14 @@
<h1>My Tweets</h1>

<?php $this->load->library('form_validation'); ?>
<?php echo validation_errors(); ?>
<?php echo form_open('user_tweets/create'); ?>
<div class="form-group">
<!--<input class="form-control" type="text" name="tweet" value="<?php echo set_value('tweet'); ?>" placeholder="What's on your mind?"/>-->
<textarea class="form-control" rows="3" name="tweet" value="<?php echo set_value('tweet'); ?>" placeholder="What's on your mind?"></textarea>
<?php echo form_error('tweet'); ?>
</div>
<button class="btn btn-primary" type="submit">Tweet</button>
<!--<input type="hidden" name="user_id" value="<?php echo 'id' // USER ID HERE for tweet creation ?>"/>-->
</form>

<div class="form-group">
<textarea class="form-control" rows="3" name="tweet" value="<?php echo set_value('tweet'); ?>" placeholder="What's on your mind?"></textarea>
<?php echo form_error('tweet'); ?>
</div>
<button class="btn btn-primary" type="submit">Tweet</button>
</form>

<?php foreach($posts as $post){ ?>
<div class="tweet-container">
Expand Down
3 changes: 1 addition & 2 deletions www/css/styles.css
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,5 @@ img.icon.reg {
}

.footer {
margin-bottom: 5px;
margin-left: 5px;
margin-left: 2em;
}

0 comments on commit 677ed0f

Please sign in to comment.